-
Notifications
You must be signed in to change notification settings - Fork 1
/
docker-compose.prod.yml
72 lines (66 loc) · 1.36 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
70
71
72
version: '3'
services:
db:
image: postgres:13-alpine
container_name: db
volumes:
- postgresql_data:/var/lib/postgresql/data
- ./init.sql:/docker-entrypoint-initdb.d/init.sql
env_file:
- .prod.env
restart: always
networks:
- insurer-network
app:
build:
context: ./backend
container_name: app
entrypoint: ["python", "docker-entrypoint.prod.py"]
volumes:
- ./backend:/usr/src/app
- static_volume:/usr/src/app/static
- media_volume:/usr/src/app/media
- log_gunicorn_volume:/var/log/
ports:
- 8000:8000
env_file:
- .prod.env
- .twilio.env
depends_on:
- db
restart: always
networks:
- insurer-network
nginx:
build: ./nginx
container_name: nginx
volumes:
- static_volume:/usr/share/nginx/html/static
- media_volume:/usr/share/nginx/html/media
- log_nginx_volume:/var/log/nginx/
ports:
- 80:80
- 443:443
depends_on:
- app
restart: always
networks:
- insurer-network
pgadmin:
image: dpage/pgadmin4
container_name: pgadmin
env_file:
- .prod.env
depends_on:
- db
ports:
- 5051:80
networks:
insurer-network:
driver: bridge
volumes:
static_volume:
media_volume:
log_gunicorn_volume:
log_nginx_volume:
postgresql_data: