Tasks

Finish

docker-compose down

Restart containers

docker-compose down
docker-compose up

Wipe database

docker-compose down
sudo mv .db/ .db.backup/

Running migrations

# with containers running, open an interactive shell with:
docker-compose run web bash
./manage.py makemigrations
./manage.py migrate

Create Django superuser

docker-compose run web bash
./manage.py createsuperuser
# login to admin dashboard at localhost:8000/admin

Rebuild

If Docker files or image change

docker-compose down
sudo mv .db/ .db.backup/
docker-compose build
docker-compose up

Set permissions for local user

pwd
# if at this project root, proceed with:
sudo chown $USER:$USER -R .