Based on tutorial https://testdriven.io/blog/dockerizing-flask-with-postgres-gunicorn-and-nginx/ $ docker-compose -f docker-compose.prod.yml down -v $ docker-compose -f docker-compose.prod.yml up -d --build $ docker-compose -f docker-compose.prod.yml exec web python manage.py create_db $ docker-compose exec db psql --username=hello_flask --dbname=hello_flask_dev