-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.prod.yml
69 lines (64 loc) · 1.39 KB
/
docker-compose.prod.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
services:
angular:
container_name: angular-prod
image: matcha/prod-angular
build:
context: ./frontend/
dockerfile: Dockerfile.prod
ports:
- '80:80'
volumes:
- uploads:/usr/share/nginx/uploads
depends_on:
- flask
networks:
- appnet
flask:
container_name: flask-prod
image: matcha/prod-flask
build:
context: ./backend/
dockerfile: Dockerfile.prod
volumes:
- ./backend:/app
- uploads:/app/uploads
ports:
- '5001:5000'
environment:
- FLASK_APP=app.py
- FLASK_ENV=production
- PYTHONUNBUFFERED=1
env_file:
- .env
command: gunicorn --worker-class eventlet -w 1 --bind 0.0.0.0:5000 matcha:app
depends_on:
- postgres
networks:
- appnet
postgres:
container_name: postgres-prod
image: postgres:latest
volumes:
- data:/var/lib/postgresql/data
- ./postgres-init:/docker-entrypoint-initdb.d
environment:
- POSTGRES_USER=${PROD_POSTGRES_USER}
- POSTGRES_PASSWORD=${PROD_POSTGRES_PASSWORD}
- POSTGRES_DB=${PROD_POSTGRES_NAME}
networks:
- appnet
mail:
container_name: mail-dev
image: mailhog/mailhog
ports:
- '1025:1025'
- '8025:8025'
networks:
- appnet
volumes:
data:
name: postgres-volume-prod
uploads:
name: uploads-volume-prod
networks:
appnet: