-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
68 lines (62 loc) · 1.33 KB
/
docker-compose.yml
File metadata and controls
68 lines (62 loc) · 1.33 KB
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
version: '3'
services:
nginx:
image: nginx:1.22
volumes:
- ./nginx/templates/default.conf.template:/etc/nginx/templates/default.conf.template
- ./nginx/ssl/:/etc/ssl/
- ./website/:/var/www/:ro # so nginx has read-only access to static files
environment:
- NGINX_HOSTNAME=${NGINX_HOSTNAME}
ports:
- 80:80
- 443:443
depends_on:
- website
website:
build: .
command: gunicorn -b 0.0.0.0:8000 -w 4 --threads 2 'website:init_app()'
restart: always
privileged: true
expose:
- 8000
env_file:
- .env
depends_on:
- celery
- redis
- mongo
volumes:
- uploads:/usr/src/app/uploads
celery:
build: .
command: celery -A website.celery_worker.celery worker --loglevel=INFO
restart: always
privileged: true
depends_on:
- redis
- mongo
volumes:
- uploads:/usr/src/app/uploads
redis:
image: redis:7.0
restart: always
expose:
- 6379
command: --requirepass ${REDIS_PASSWORD}
volumes:
- cache:/data
mongo:
image: mongo:6.0
restart: always
expose:
- 27017
environment:
- MONGO_INITDB_ROOT_USERNAME=${MONGO_USERNAME}
- MONGO_INITDB_ROOT_PASSWORD=${MONGO_PASSWORD}
volumes:
- db:/data/db
volumes:
cache:
db:
uploads: