-
Notifications
You must be signed in to change notification settings - Fork 47
/
Copy pathdocker-compose.yml
99 lines (98 loc) · 2.37 KB
/
docker-compose.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
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
version: "3.7"
networks:
merginmaps:
services:
db:
image: postgres:14
container_name: merginmaps-db
restart: always
networks:
- merginmaps
environment:
- POSTGRES_USER=postgres
- POSTGRES_PASSWORD=postgres
volumes:
- ./mergin_db:/var/lib/postgresql/data
redis:
image: redis
container_name: merginmaps-redis
restart: always
networks:
- merginmaps
server-gunicorn:
image: lutraconsulting/merginmaps-backend:2024.2.2
container_name: merginmaps-server
restart: always
user: 901:999
volumes:
- ./projects:/data
- ./server/entrypoint.sh:/app/entrypoint.sh
env_file:
- .prod.env
depends_on:
- db
- redis
command: [ "gunicorn --config config.py application:application" ]
networks:
- merginmaps
celery-beat:
image: lutraconsulting/merginmaps-backend:2024.2.2
container_name: celery-beat
restart: always
env_file:
- .prod.env
environment:
- GEVENT_WORKER=0
- NO_MONKEY_PATCH=1
volumes:
- ./server/entrypoint.sh:/app/entrypoint.sh
depends_on:
- redis
- server-gunicorn
command: [ "celery -A application.celery beat --loglevel=info" ]
networks:
- merginmaps
celery-worker:
image: lutraconsulting/merginmaps-backend:2024.2.2
container_name: celery-worker
restart: always
user: 901:999
env_file:
- .prod.env
environment:
- GEVENT_WORKER=0
- NO_MONKEY_PATCH=1
volumes:
- ./projects:/data
- ./server/entrypoint.sh:/app/entrypoint.sh
depends_on:
- redis
- server-gunicorn
- celery-beat
command: [ "celery -A application.celery worker --loglevel=info" ]
networks:
- merginmaps
web:
image: lutraconsulting/merginmaps-frontend:2024.2.2
container_name: merginmaps-web
restart: always
depends_on:
- server-gunicorn
links:
- db
networks:
- merginmaps
proxy:
image: nginxinc/nginx-unprivileged:1.25.5
container_name: merginmaps-proxy
restart: always
# run nginx as built-in user but with group mergin-family for files permissions
user: 101:999
ports:
- "8080:8080"
volumes:
- ./projects:/data # map data dir to host
- ./nginx.conf:/etc/nginx/conf.d/default.conf
- ./logs:/var/log/nginx/
networks:
- merginmaps