-
Notifications
You must be signed in to change notification settings - Fork 1
/
docker-compose.prod.yml
77 lines (70 loc) · 1.29 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
73
74
75
76
77
version: '3.8'
services:
mongo_gptv:
image: mongo
command: ['--replSet', 'rs0', '--bind_ip_all']
ports:
- 27017:27017
volumes:
- ./storage/mongodb_data:/data/db
- ./config/mongo-config:/data/configdb
networks:
- mongo-net
mongosetup:
image: mongo
depends_on:
- mongo_gptv
volumes:
- ./database/mongodb/scripts:/scripts
restart: 'no'
entrypoint:
[
'bash',
'/scripts/wait-for-it.sh',
'mongo_gptv:27017',
'--',
'bash',
'/scripts/init.sh',
]
networks:
- mongo-net
gptv_backend:
build:
context: .
dockerfile: Dockerfile.prod
volumes:
- .:/app
- /app/tmp
ports:
- 8080:8080
depends_on:
- mongo_gptv
- redis
- mongosetup
networks:
- mongo-net
env_file:
- ./config/prod.env
redis:
image: redis
ports:
- 6379:6379
networks:
- mongo-net
nginx:
context: .
dockerfile: Dockerfile.nginx.prod
image: nginx:latest
ports:
- 80:80
volumes:
- ./config/nginx-config/nginx.prod.conf:/etc/nginx/nginx.conf
depends_on:
- gptv_backend
networks:
- mongo-net
volumes:
mongodb_data:
mongodb_config:
networks:
mongo-net: