-
Notifications
You must be signed in to change notification settings - Fork 8
/
Copy pathdocker-compose.yaml
81 lines (79 loc) · 1.41 KB
/
docker-compose.yaml
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
version: "3.3"
services:
nginx:
container_name: nginx
depends_on:
- django
build:
context: ./nginx
dockerfile: Dockerfile
ports:
- "8080:80"
volumes:
- ./django/rest/staticfiles:/static
- ./django/rest/mediafiles:/media
networks:
- rest-api
db:
container_name: postgres
image: kartoza/postgis:12.1
env_file:
- db.env
volumes:
- django-postgres:/var/lib/postgresql/data
networks:
- rest-api
django:
restart: always
container_name: django
image: django
build:
context: ./django
dockerfile: Dockerfile
command: uwsgi --ini ./uwsgi/uwsgi.ini
volumes:
- ./django:/code
depends_on:
- db
env_file:
- db.env
networks:
- rest-api
redis:
image: redis:alpine
networks:
- rest-api
celery:
restart: always
build:
context: ./django
command: celery -A rest worker -l info -E
volumes:
- ./django:/code
env_file:
- db.env
depends_on:
- db
- redis
- django
networks:
- rest-api
celery-beat:
restart: always
build:
context: ./django
command: celery -A rest beat -l info
volumes:
- ./django:/code
env_file:
- db.env
depends_on:
- db
- redis
- django
networks:
- rest-api
networks:
rest-api:
volumes:
django-postgres: