version: '3'

services:
  app:
    restart: always
    build: .
    # map the local (host) directories to their container counterparts
    # to support live-syncing
    volumes:
      - ./sampleproj:/app/sampleproj/
      - ./mdot-rest:/app/mdot-rest
    ports:
      - "${PORT:-8000}:8000"
    command: >
      bash -c "python manage.py migrate --settings=sampleproj.settings.local
      && python manage.py createsuperuser --username javerage --email javerage@example.com --noinput --settings=sampleproj.settings.local
      && python manage.py runserver 0:8000 --settings=sampleproj.settings.local"

version: '3'

services:
  app:
    restart: always
    build: .
    # map the local (host) directories to their container counterparts
    # to support live-syncing
    volumes:
      - ./sampleproj:/app/sampleproj/
      - ./mdot-rest:/app/mdot-rest
    ports:
      - "${PORT:-8000}:8000"
    command: >
      bash -c "rm sampleproj/db.sqlite3
      && python manage.py migrate --settings=sampleproj.settings.local
      && python manage.py createsuperuser --username javerage --email javerage@example.com --noinput --settings=sampleproj.settings.local
      && python manage.py runserver 0:8000 --settings=sampleproj.settings.local"

Delete db so unique superuser can be created again.
Delete db so unique superuser can be created again.

We'll clean this up when we fix up the newer docker container.
