- Enable docker daemon
1
sudo systemctl enable docker
- Add
restart
option todocker-compose.yml
1 2 3 4 5 6 7 8 9 10 11 12 13
web: restart: always build: . container_name: web01 command: bash -c " python manage_dev.py collectstatic --no-input && python manage_dev.py makemigrations && python manage_dev.py migrate && gunicorn knu_notice.dev.wsgi -b 0:8080 --reload" volumes: - ./knu_notice:/home/knu_notice links: - redis