net/docker-compose.prod.yml

38 lines
748 B
YAML

version: '3.8'
services:
flask:
build:
context: ./flask
dockerfile: Dockerfile.prod
command: gunicorn --bind 0.0.0.0:5000 manage:app
volumes:
- static_volume:/home/app/web/forest/static
- media_volume:/home/app/web/forest/media
expose:
- 5000
env_file:
- ./.env.prod
depends_on:
- db
db:
image: postgres:13-alpine
volumes:
- postgres_data_prod:/var/lib/postgresql/data/
env_file:
- ./.env.prod
nginx:
build: ./nginx
volumes:
- static_volume:/home/app/web/forest/static
- media_volume:/home/app/web/forest/media
ports:
- 1337:80
depends_on:
- web
volumes:
postgres_data_prod:
static_volume:
media_volume: