-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.dev.yml
91 lines (83 loc) · 1.76 KB
/
docker-compose.dev.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
services:
web:
build:
context: ./src
dockerfile: Dockerfile
image: webapp_django
restart: always
command: gunicorn base.wsgi:application --bind 0.0.0.0:8000 --workers 3 --timeout 90
volumes:
- static_volume:/home/app/web/static
- media_volume:/home/app/web/media
expose:
- 8000
env_file:
- ./config/django.cfg
depends_on:
- db
- db_gold
networks:
app_network:
ipv4_address: 192.168.100.2
djangoq:
build:
context: ./src
dockerfile: Dockerfile
image: django_q
restart: always
command: python manage.py qcluster
volumes:
- static_volume:/home/app/web/static
- media_volume:/home/app/web/media
expose:
- 8000
env_file:
- ./config/django.cfg
depends_on:
- db
- db_gold
networks:
app_network:
ipv4_address: 192.168.100.6
db:
image: postgres:15
volumes:
- postgres_data:/var/lib/postgresql/data/
env_file:
- ./config/db.cfg
networks:
app_network:
ipv4_address: 192.168.100.3
db_gold:
image: postgres:15
volumes:
- postgres_data_gold:/var/lib/postgresql/data/
env_file:
- ./config/gold.cfg
networks:
app_network:
ipv4_address: 192.168.100.4
nginx:
image: nginx:latest
volumes:
- static_volume:/home/app/web/static
- media_volume:/home/app/web/media
- ./nginx/nginx.dev.conf:/etc/nginx/nginx.conf:ro
ports:
- 80:80
restart: always
depends_on:
- web
networks:
- app_network
volumes:
postgres_data:
postgres_data_gold:
static_volume:
media_volume:
networks:
app_network:
driver: bridge
ipam:
config:
- subnet: 192.168.100.0/24