-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdocker-compose.yml
214 lines (203 loc) · 5.02 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
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
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
services:
bl-central-server:
hostname: bl-central-server
container_name: bl-central-server
build:
context: bl-central-server/bl-central-streaming/.
deploy:
resources:
limits:
memory: 300M
# reservations:
# memory: 300M
healthcheck:
test: ["CMD", "curl", "--silent", "http://127.0.0.1:15672"]
interval: 5s
timeout: 5m
retries: 60
depends_on:
bl-train-01-rabbitmq-server:
condition: service_healthy
bl-bridge-01-rabbitmq-server:
condition: service_healthy
bl-central-psql:
condition: service_healthy
bl-central-cassandra:
condition: service_healthy
networks:
- bl-net
bl-readers:
hostname: bl-readers
container_name: bl-readers
build:
context: bl-central-server/bl-central-readings/.
deploy:
resources:
limits:
memory: 2000M
# reservations:
# memory: 2000M
healthcheck:
test: ["CMD", "curl", "--silent", "http://127.0.0.1:4040"]
interval: 5s
timeout: 5m
retries: 60
depends_on:
bl-central-kafka-server:
condition: service_healthy
bl-central-cassandra:
condition: service_healthy
networks:
- bl-net
bl-central-kafka-server:
hostname: bl-central-kafka-server
container_name: bl-central-kafka-server
build:
context: bl-central-server/kafka/.
deploy:
resources:
limits:
memory: 1000M
# reservations:
# memory: 1000M
depends_on:
bl-train-01-rabbitmq-server:
condition: service_healthy
bl-central-psql:
condition: service_healthy
healthcheck:
test: ["CMD-SHELL", "kafka-topics --bootstrap-server 127.0.0.1:9092 --topic PASSENGER --describe"]
interval: 10s
timeout: 5m
retries: 30
networks:
- bl-net
bl-train-01-rabbitmq-server:
hostname: bl-train-01-rabbitmq-server
container_name: bl-train-01-rabbitmq-server
build:
context: bl-train-server/rabbitmq/.
deploy:
resources:
limits:
memory: 400M
reservations:
memory: 400M
healthcheck:
test: ["CMD", "curl", "--silent", "http://127.0.0.1:15672"]
interval: 5s
timeout: 5m
retries: 60
networks:
- bl-net
bl-bridge-01-sensors-server:
hostname: bl-bridge-01-sensors-server
container_name: bl-bridge-01-sensors-server
build:
context: bl-bridge-server/.
deploy:
resources:
limits:
memory: 100M
depends_on:
bl-central-kafka-server:
condition: service_healthy
networks:
- bl-net
bl-bridge-01-mosquitto_server:
hostname: bl-bridge-01-mosquitto_server
container_name: bl-bridge-01-mosquitto_server
build:
context: bl-bridge-server/mosquitto/.
deploy:
resources:
limits:
memory: 50M
networks:
- bl-net
bl-bridge-01-rabbitmq-server:
hostname: bl-bridge-01-rabbitmq-server
container_name: bl-bridge-01-rabbitmq-server
build:
context: bl-bridge-server/rabbitmq/.
deploy:
resources:
limits:
memory: 400M
reservations:
memory: 400M
healthcheck:
test: ["CMD", "curl", "--silent", "http://127.0.0.1:15672"]
interval: 5s
timeout: 240s
retries: 60
networks:
- bl-net
bl-central-psql:
hostname: bl-central-psql
container_name: bl-central-psql
build:
context: bl-central-server/bl-central-psql/.
environment:
- POSTGRES_USER=postgres
- POSTGRES_PASSWORD=admin
- POSTGRES_MULTIPLE_DATABASES=bllogistics
deploy:
resources:
limits:
memory: 100M
healthcheck:
test: [ "CMD", "pg_isready", "-U", "postgres" ]
interval: 30s
timeout: 30s
retries: 10
start_period: 0s
networks:
- bl-net
bl-central-server-apps:
hostname: bl-central-server-apps
container_name: bl-central-server-apps
build:
context: bl-central-server/.
expose:
- 9000
depends_on:
bl-central-psql:
condition: service_healthy
bl-central-server:
condition: service_healthy
bl-train-01-rabbitmq-server:
condition: service_healthy
bl-central-cassandra:
condition: service_healthy
deploy:
resources:
limits:
memory: 800M
# reservations:
# memory: 800M
networks:
- bl-net
bl-central-cassandra:
hostname: bl-central-cassandra
container_name: bl-central-cassandra
build:
context: bl-central-server/bl-central-cassandra/.
environment:
- "MAX_HEAP_SIZE=64M"
- "HEAP_NEWSIZE=64M"
healthcheck:
test: ["CMD", "cqlsh", "-u cassandra", "-p cassandra" ,"-e describe keyspaces"]
interval: 15s
timeout: 10s
retries: 10
deploy:
resources:
limits:
memory: 500M
reservations:
memory: 500M
networks:
- bl-net
networks:
bl-net: