-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
531 lines (496 loc) · 15.3 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
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
# ---------------------------------------------------------------------------------------
# Postgres
# YTI Fuseki
# YTI Groupmanagement - Groupmanagement API + UI bundle
# YTI ActiveMQ - Active MQ
# YTI Codelist - Intake Service
# YTI Codelist - Public API Service
# YTI Codelist - UI
# YTI Codelist - ElasticSearch
# YTI Terminology - Termed API
# YTI Terminology - ElasticSearch
# YTI Terminology - API
# YTI Terminology - UI
# YTI Datamodel - API
# YTI Datamodel - UI
# YTI Datamodel - ElasticSEarch
# YTI Comments - API
# YTI Comments - UI
# ---------------------------------------------------------------------------------------
version: '3'
services:
# KIBANA
# Just uncomment if you need to analyze indexes
#yti-codelist-kibana:
# image: docker.elastic.co/kibana/kibana:6.5.4
# container_name: yti-kibana
# restart: "no"
# ports:
# - "5601:5601"
# environment:
# ELASTICSEARCH_URL: http://yti-codelist-elasticsearch:9200
# networks:
# - yti-network
#yti-terminology-kibana:
# image: docker.elastic.co/kibana/kibana:6.5.4
# container_name: yti-kibana
# restart: "no"
# ports:
# - "5602:5601"
# environment:
# ELASTICSEARCH_URL: http://yti-terminology-elasticsearch:9200
# networks:
# - yti-network
#yti-datamodel-kibana:
# image: docker.elastic.co/kibana/kibana:6.5.4
# container_name: yti-kibana
# restart: "no"
# ports:
# - "5603:5601"
# environment:
# ELASTICSEARCH_URL: http://yti-datamodel-elasticsearch:9200
# networks:
# - yti-network
# POSTGRES
yti-postgres:
image: yti-postgres:latest
container_name: yti-postgres
restart: "no"
ports:
- "5432:5432"
volumes:
- ${YTI_COMPOSE_LOGS}/yti-postgres:/data/logs/yti-postgres:Z
- ${YTI_COMPOSE_DATA}/yti-postgres:/var/lib/postgresql/data:Z
command: postgres -c logging_collector=on -c log_directory=/data/logs/yti-postgres
environment:
# do not require password in local environment
POSTGRES_HOST_AUTH_METHOD: trust
healthcheck:
test: ["CMD-SHELL", "pg_isready -U postgres -d groupmanagement"]
interval: 30s
timeout: 5s
retries: 3
networks:
- yti-network
# ACTIVEMQ
yti-activemq:
image: yti-activemq:latest
container_name: yti-activemq
restart: "no"
ports:
- "9900:8161"
- "9901:61616"
environment:
- "ARTEMIS_USERNAME=yti"
- "ARTEMIS_PASSWORD=test"
- "ARTEMIS_MIN_MEMORY=512M"
- "ARTEMIS_MAX_MEMORY=512M"
volumes:
- ${YTI_COMPOSE_LOGS}/yti-activemq:/var/lib/artemis/log:z
networks:
- yti-network
# GROUPMANAGEMENT
yti-groupmanagement:
image: yti-groupmanagement:latest
container_name: yti-groupmanagement
restart: "no"
ports:
- "9302:9302"
- "9300:9300"
volumes:
- ./config:/config:z
environment:
- "SPRING_PROFILES_ACTIVE=docker"
- "SPRING_CONFIG_LOCATION=/config/application.yml,/config/yti-groupmanagement.yml"
healthcheck:
test: ["CMD-SHELL", "wget -q --tries=1 -O /dev/null http://localhost:9302/ || exit 1"]
interval: 30s
timeout: 5s
retries: 3
depends_on:
yti-postgres:
condition: service_healthy
networks:
- yti-network
# CODELIST
yti-codelist-elasticsearch:
image: docker.elastic.co/elasticsearch/elasticsearch:6.8.22
container_name: yti-codelist-elasticsearch
restart: "no"
ports:
- "9610:9200"
environment:
- xpack.security.enabled=false
- cluster.name=yti-codelist-elasticsearch
- http.host=0.0.0.0
- transport.host=0.0.0.0
- network.publish_host=127.0.0.1
- discovery.type=single-node
- "ES_JAVA_OPTS=-Xms1024m -Xmx1024m"
healthcheck:
test: ["CMD-SHELL", "curl -qs 'http://localhost:9200/_cluster/health?timeout=5s' | sed -E 's/.*\"status\":\"?([^,\"]*)\"?.*/\\1/' | grep -e yellow -e green"]
interval: 30s
timeout: 5s
retries: 3
networks:
- yti-network
yti-codelist-ui:
image: yti-codelist-ui:latest
container_name: yti-codelist-ui
privileged: true
restart: "no"
ports:
- "9600:80"
depends_on:
yti-codelist-content-intake-service:
condition: service_healthy
yti-codelist-public-api-service:
condition: service_healthy
networks:
- yti-network
yti-codelist-content-intake-service:
image: yti-codelist-content-intake-service:latest
container_name: yti-codelist-content-intake-service
restart: "no"
ports:
- "9602:9602"
- "9603:9603"
- "19602:19602"
volumes:
- ./config:/config:z
- ${YTI_COMPOSE_DATA}/yti-codelist-intake:/data/yti/yti-codelist-intake:Z
command: -j -Xmx2048M -a --spring.profiles.active=default,docker --spring.config.location=/config/application.yml,/config/yti-codelist-content-intake-service.yml
healthcheck:
test: ["CMD-SHELL", "wget -q --tries=1 -O - http://localhost:9602/codelist-intake/actuator/health | grep '\"status\":\"UP\"' || exit 1"]
interval: 30s
timeout: 5s
retries: 3
depends_on:
yti-groupmanagement:
condition: service_healthy
yti-codelist-elasticsearch:
condition: service_healthy
yti-postgres:
condition: service_healthy
networks:
- yti-network
yti-codelist-public-api-service:
image: yti-codelist-public-api-service:latest
container_name: yti-codelist-public-api-service
restart: "no"
ports:
- "9601:9601"
- "19601:19601"
volumes:
- ./config:/config:z
- ${YTI_COMPOSE_DATA}/yti-codelist-api:/data/yti/yti-codelist-api:Z
- ${YTI_COMPOSE_LOGS}/yti-codelist-api:/data/logs/yti-codelist-api:Z
command: -j -Xmx512M -a --spring.profiles.active=default,docker --spring.config.location=/config/application.yml,/config/yti-codelist-public-api-service.yml
healthcheck:
test: ["CMD-SHELL", "wget -q --tries=1 -O - http://localhost:9601/codelist-api/actuator/health | grep '\"status\":\"UP\"' || exit 1"]
interval: 30s
timeout: 5s
retries: 3
depends_on:
yti-codelist-elasticsearch:
condition: service_healthy
networks:
- yti-network
# TERMINOLOGY
yti-terminology-termed-api:
image: "yti-terminology-termed-api:latest"
container_name: "yti-terminology-termed-api"
restart: "no"
environment:
- SPRING_PROFILES_ACTIVE=default,docker
- SPRING_CONFIG_LOCATION=/config/yti-terminology-termed-api.properties
ports:
- "9102:8080"
volumes:
- ./config:/config:z
- ${YTI_COMPOSE_LOGS}/yti-terminology-termed-api:/data/logs/yti-terminology-termed-api:Z
healthcheck:
test: ["CMD-SHELL", "wget -q --tries=1 -O - http://admin:admin@localhost:8080/health | grep '\"code\": \"UP\"' || exit 1"]
interval: 30s
timeout: 5s
retries: 3
depends_on:
yti-postgres:
condition: service_healthy
networks:
- yti-network
yti-terminology-elasticsearch:
image: docker.elastic.co/elasticsearch/elasticsearch:6.8.22
container_name: "yti-terminology-elasticsearch"
restart: "no"
ports:
- "9104:9200"
environment:
- xpack.security.enabled=false
- transport.host=127.0.0.1
- http.host=0.0.0.0
- "ES_JAVA_OPTS=-Xms512m -Xmx512m"
healthcheck:
test: ["CMD-SHELL", "curl -qs 'http://localhost:9200/_cluster/health?timeout=5s' | sed -E 's/.*\"status\":\"?([^,\"]*)\"?.*/\\1/' | grep -e yellow -e green"]
interval: 30s
timeout: 5s
retries: 3
networks:
- yti-network
yti-terminology-api:
image: "yti-terminology-api:latest"
container_name: "yti-terminology-api"
restart: "no"
environment:
- SPRING_PROFILES_ACTIVE=default,docker
- SPRING_CONFIG_LOCATION=/config/application.yml,/config/yti-terminology-api.yml
ports:
- "9101:9101"
- "9103:9103"
volumes:
- ./config:/config:z
- ${YTI_COMPOSE_LOGS}/yti-terminology-api:/data/logs/yti-terminology-api:Z
healthcheck:
test: ["CMD-SHELL", "wget -q --tries=1 -O - http://localhost:9103/terminology-api/actuator/health | grep '\"status\":\"UP\"' || exit 1"]
interval: 30s
timeout: 5s
retries: 3
depends_on:
yti-groupmanagement:
condition: service_healthy
yti-terminology-elasticsearch:
condition: service_healthy
yti-terminology-termed-api:
condition: service_healthy
yti-activemq:
condition: service_started
yti-postgres:
condition: service_healthy
networks:
- yti-network
yti-terminology-api-v2:
image: "yti-terminology-api-v2:latest"
container_name: "yti-terminology-api-v2"
restart: "no"
environment:
- SPRING_PROFILES_ACTIVE=default,docker
- SPRING_CONFIG_LOCATION=/config/application.yml,/config/yti-terminology-api-v2.yml
ports:
- "9101:9101"
- "9103:9103"
volumes:
- ./config:/config:z
healthcheck:
test: ["CMD-SHELL", "wget -q --tries=1 -O - http://localhost:9103/terminology-api/actuator/health | grep '\"status\":\"UP\"' || exit 1"]
interval: 30s
timeout: 5s
retries: 3
depends_on:
yti-groupmanagement:
condition: service_healthy
yti-datamodel-opensearch:
condition: service_healthy
yti-activemq:
condition: service_started
yti-fuseki-v4:
condition: service_started
networks:
- yti-network
yti-terminology-ui:
image: "yti-terminology-ui:latest"
container_name: "yti-terminology-ui"
privileged: true
restart: "no"
ports:
- "9100:80"
environment:
- TERMINOLOGY_API_URL=http://yti-terminology-api:9103/terminology-api
- SECRET_COOKIE_PASSWORD=secret-cookie-password-for-local-development
- ENV_TYPE=dev
- REWRITE_PROFILE=docker
depends_on:
yti-terminology-api:
condition: service_healthy
networks:
- yti-network
# DATAMODEL
yti-datamodel-ui:
image: "yti-datamodel-ui:latest"
container_name: "yti-datamodel-ui"
restart: "no"
ports:
- "9000:80"
environment:
- TERMINOLOGY_API_URL=http://yti-terminology-api:9103/terminology-api
- DATAMODEL_API_URL=http://yti-datamodel-api:9004/datamodel-api
- SECRET_COOKIE_PASSWORD=secret-cookie-password-for-local-development
- ENV_TYPE=dev
- REWRITE_PROFILE=docker
networks:
- yti-network
depends_on:
yti-datamodel-api:
condition: service_healthy
yti-datamodel-elasticsearch:
image: "docker.elastic.co/elasticsearch/elasticsearch:6.8.22"
container_name: "yti-datamodel-elasticsearch"
restart: "no"
ports:
- "9002:9200"
environment:
- xpack.security.enabled=false
- cluster.name=yti-datamodel-elasticsearch
- http.host=0.0.0.0
- network.publish_host=127.0.0.1
- discovery.type=single-node
- "ES_JAVA_OPTS=-Xms512m -Xmx512m"
volumes:
- ${YTI_COMPOSE_LOGS}/yti-datamodel-elasticsearch:/usr/share/elasticsearch/logs:Z
healthcheck:
test: ["CMD-SHELL", "curl -qs 'http://localhost:9200/_cluster/health?timeout=5s' | sed -E 's/.*\"status\":\"?([^,\"]*)\"?.*/\\1/' | grep -e yellow -e green"]
interval: 30s
timeout: 5s
retries: 3
networks:
- yti-network
yti-datamodel-opensearch:
image: "opensearchproject/opensearch:2.3.0"
container_name: "yti-datamodel-opensearch"
restart: "no"
ports:
- "9003:9200"
environment:
- cluster.name=opensearch-cluster
- node.name=opensearch-node1
- bootstrap.memory_lock=true
- "OPENSEARCH_JAVA_OPTS=-Xms512m -Xmx512m"
- "DISABLE_INSTALL_DEMO_CONFIG=true"
- "DISABLE_SECURITY_PLUGIN=true"
- "discovery.type=single-node"
volumes:
- ${YTI_COMPOSE_LOGS}/yti-datamodel-opensearch:/usr/share/opensearch/logs:Z
healthcheck:
test: ["CMD-SHELL", "curl -qs 'http://localhost:9200/_cluster/health?timeout=5s' | sed -E 's/.*\"status\":\"?([^,\"]*)\"?.*/\\1/' | grep -e yellow -e green"]
interval: 30s
timeout: 5s
retries: 3
networks:
- yti-network
yti-datamodel-api:
image: "yti-datamodel-api:latest"
container_name: "yti-datamodel-api"
expose:
- "9001"
- "9004"
ports:
- "9001:9001"
- "9004:9004"
environment:
- SPRING_PROFILES_ACTIVE=docker
- SPRING_CONFIG_LOCATION=/config/application.yml,/config/yti-datamodel-api.yml
volumes:
- ./config:/config:z
- ${YTI_COMPOSE_LOGS}/yti-datamodel-api:/data/logs/yti-datamodel-api:Z
depends_on:
yti-fuseki-v4:
condition: service_healthy
yti-fuseki:
condition: service_healthy
yti-groupmanagement:
condition: service_healthy
yti-datamodel-elasticsearch:
condition: service_healthy
yti-terminology-termed-api:
condition: service_healthy
yti-datamodel-opensearch:
condition: service_healthy
networks:
- yti-network
yti-fuseki:
image: "yti-fuseki:latest"
container_name: "yti-fuseki"
restart: "no"
ports:
- "3030:3030"
volumes:
- ${YTI_COMPOSE_DATA}/yti-fuseki:/fuseki:Z
healthcheck:
test: ["CMD-SHELL", "wget -q --tries=1 -O /dev/null http://localhost:3030/$$/ping || exit 1"]
interval: 30s
timeout: 5s
retries: 3
networks:
- yti-network
yti-fuseki-v4:
image: "yti-fuseki-v4:latest"
container_name: "yti-fuseki-v4"
restart: "no"
ports:
- "3031:3030"
volumes:
- ${YTI_COMPOSE_LOGS}/yti-fuseki-v4:/fuseki/logs:Z
- ${YTI_COMPOSE_DATA}/yti-fuseki-v4:/fuseki/databases:Z
healthcheck:
test: ["CMD-SHELL", "wget -q --tries=1 -O /dev/null http://localhost:3030/$$/ping || exit 1"]
interval: 30s
timeout: 5s
retries: 3
networks:
- yti-network
# COMMENTS
yti-comments-api:
image: "yti-comments-api:latest"
container_name: "yti-comments-api"
restart: "no"
ports:
- "9701:9701"
volumes:
- ./config:/config:z
- ${YTI_COMPOSE_LOGS}/yti-comments-api:/data/logs/yti-comments-api:Z
command: -j -Xmx2048M -a --spring.profiles.active=default,docker --spring.config.location=/config/application.yml,/config/yti-comments-api.yml
healthcheck:
test: ["CMD-SHELL", "wget -q --tries=1 -O - http://localhost:9701/comments-api/actuator/health | grep '\"status\":\"UP\"' || exit 1"]
interval: 30s
timeout: 5s
retries: 3
depends_on:
yti-groupmanagement:
condition: service_healthy
yti-postgres:
condition: service_healthy
networks:
- yti-network
yti-comments-ui:
image: "yti-comments-ui:latest"
container_name: "yti-comments-ui"
restart: "no"
ports:
- "9700:80"
volumes:
- ${YTI_COMPOSE_LOGS}/yti-comments-ui:/data/logs/yti-comments-ui:Z
depends_on:
yti-comments-api:
condition: service_healthy
networks:
- yti-network
# MESSAGING
yti-messaging-api:
image: "yti-messaging-api:latest"
container_name: "yti-messaging-api"
restart: "no"
ports:
- "9801:9801"
volumes:
- ./config:/config:z
- ${YTI_COMPOSE_LOGS}/yti-messaging-api:/data/logs/yti-messaging-api:Z
command: -j -Xmx2048M -a --spring.profiles.active=default,docker --spring.config.location=/config/application.yml,/config/yti-messaging-api.yml
depends_on:
yti-groupmanagement:
condition: service_healthy
yti-postgres:
condition: service_healthy
networks:
- yti-network
networks:
yti-network:
driver: bridge