-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose_without_keys.yml
More file actions
133 lines (127 loc) · 2.9 KB
/
docker-compose_without_keys.yml
File metadata and controls
133 lines (127 loc) · 2.9 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
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
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
version: "2"
services:
# postgres:
# mem_limit: 1024m
# #image: kartoza/postgis:9.6-2.4
# image: postgres:9.6
# # environment:
# # - POSTGRES_USER=docker
# # - POSTGRES_PASS=docker
# networks:
# - halalivery-backend-tier
# ports:
# - "5432:5432"
postgis:
mem_limit: 1024m
image: kartoza/postgis:9.6-2.4
environment:
- POSTGRES_USER=docker
- POSTGRES_PASS=docker
networks:
- halalivery-backend-tier
ports:
- "5432:5432"
web:
mem_limit: 512m
restart: always
networks:
- halalivery-backend-tier
environment:
- DJANGO_DEBUG=Yes
- DJANGO_SECRET_KEY=local
- DJANGO_CONFIGURATION=Local
- DJANGO_SETTINGS_MODULE=halalivery.config
- CELERY_BROKER_URL=redis://redis:6379/0
image: web
build: ./
command: >
bash -c "python wait_for_postgis.py &&
./manage.py makemigrations &&
./manage.py migrate &&
./manage.py collectstatic --noinput &&
./manage.py runserver 0.0.0.0:8000"
volumes:
- ./:/code
ports:
- "8000:8000"
depends_on:
- postgis
documentation:
mem_limit: 256m
image: documentation
restart: always
build: ./
command: "mkdocs serve"
networks:
- halalivery-backend-tier
volumes:
- ./:/code
ports:
- "8001:8001"
celery:
mem_limit: 256m
image: celery
build:
context: .
dockerfile: ./Dockerfile
args:
STATIC_URL: "/static/"
environment:
- DJANGO_SECRET_KEY=local
- DJANGO_DEBUG=Yes
- DJANGO_CONFIGURATION=Local
- CELERY_BROKER_URL=redis://redis:6379/0
command: bash -c "celery -A halalivery worker --app=halalivery.celeryconf:app --loglevel=info"
restart: always
networks:
- halalivery-backend-tier
volumes:
- ./:/code
depends_on:
- postgis
- web
- redis
celery-beat:
mem_limit: 128m
image: celery-beat
build:
context: .
dockerfile: ./Dockerfile
args:
STATIC_URL: "/static/"
environment:
- DJANGO_SECRET_KEY=local
- DJANGO_DEBUG=Yes
- DJANGO_CONFIGURATION=Local
- CELERY_BROKER_URL=redis://redis:6379/0
command: bash -c "celery -A halalivery beat --loglevel=info --scheduler django_celery_beat.schedulers:DatabaseScheduler --quiet"
restart: always
volumes:
- ./:/code
networks:
- halalivery-backend-tier
depends_on:
- postgis
- web
- redis
- celery
redis:
mem_limit: 256m
image: library/redis:latest
restart: unless-stopped
networks:
- halalivery-backend-tier
volumes:
- halalivery-redis:/data
ports:
- 6379:6379
volumes:
halalivery-db:
driver: local
halalivery-redis:
driver: local
halalivery-search:
driver: local
networks:
halalivery-backend-tier:
driver: bridge