forked from I-TECH-UW/ci-hie-demo
-
Notifications
You must be signed in to change notification settings - Fork 9
/
docker-compose-pilot.yml
249 lines (234 loc) · 7.53 KB
/
docker-compose-pilot.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
version: '3.8'
services:
sigdep3:
image: partnersinhealth/openmrs-server:latest
restart: unless-stopped
depends_on:
sigdep-db:
condition: service_healthy
container_name: sigdep3
hostname: sigdep3
healthcheck:
test:
- CMD
- curl
- "-f"
- "http://localhost:8080/openmrs/"
timeout: 5s
environment:
OMRS_CONFIG_CONNECTION_SERVER: "sigdep-db"
OMRS_CONFIG_CONNECTION_ROOT_PASSWORD: "root"
OMRS_CONFIG_CONNECTION_USERNAME: "root"
OMRS_CONFIG_CONNECTION_PASSWORD: "root"
OMRS_CONFIG_CONNECTION_EXTRA_ARGS: "&autoReconnect=true&sessionVariables=default_storage_engine%3DInnoDB&useUnicode=true&characterEncoding=UTF-8&useSSL=false&requireSSL=false"
OMRS_CONFIG_AUTO_UPDATE_DATABASE: "false"
OMRS_CONFIG_CREATE_TABLES: "false"
OMRS_CONFIG_HAS_CURRENT_OPENMRS_DATABASE: "true"
OMRS_DEV_DEBUG_PORT: "1044"
clientregistry.serverUrl: ${CLIENTREGISTRY_SERVERURL}
clientregistry.username: ${CLIENTREGISTRY_USERNAME}
clientregistry.password: ${CLIENTREGISTRY_PASSWORD}
clientregistry.identifierRoot: ${CLIENTREGISTRY_IDENTIFIERROOT}
#clientregistry.serverUrl: "https://test25.cihis.org/openhimcore/CR/fhir"
volumes:
- ./configs/sigdep3/distribution:/openmrs/distribution
# uncomment to persist the volumes on the Host file system
#- .data/sigdep3:/openmrs/data
ports:
- "8080:8080"
- "1044:1044"
sigdep-db:
image: library/mysql:5.6
restart: unless-stopped
hostname: sigdep-db
container_name: sigdep-db
command: "mysqld \
--character-set-server=utf8 \
--collation-server=utf8_general_ci \
--max_allowed_packet=1G \
--default-authentication-plugin=mysql_native_password \
--sql_mode=STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_ENGINE_SUBSTITUTION"
environment:
MYSQL_DATABASE: "openmrs"
MYSQL_ROOT_PASSWORD: "root"
healthcheck:
test: [ "CMD", "mysqladmin" ,"ping", "-h", "localhost" ]
timeout: 20s
retries: 10
depends_on:
openhim-console:
condition: service_healthy
volumes:
- ./configs/sigdep3/mysql.cnf:/etc/mysql/conf.d/custom.cnf # mysql config preconfigured to allow binlog/debezium
- ./configs/sigdep3/init-db:/docker-entrypoint-initdb.d
# uncomment to persist the volumes on the Host file system
#- .db/sigdep3:/var/lib/mysql
ports:
- "3307:3306"
#OpenHIM -IOL
mongo:
container_name: openhim-mongo
ports:
- "27017:27017"
image: mongo:3.4
openhim-core:
container_name: openhim-core
image: jembi/openhim-core:v7.1.0
restart: unless-stopped
environment:
- mongo_url=mongodb://mongo/openhim
- mongo_atnaUrl=mongodb://mongo/openhim
healthcheck:
test: "node /healthcheck.js"
interval: 20s
timeout: 20s
retries: 2
volumes:
- ./configs/openhim/healthcheck.js:/healthcheck.js
ports:
- "8085:8080"
- "5000:5000"
- "5001:5001"
- "5050:5050"
- "5051:5051"
- "5052:5052"
- "7788:7788"
depends_on:
- mongo
openhim-console:
container_name: openhim-console
image: jembi/openhim-console:v1.15.0
ports:
- "9000:80"
volumes:
- ./configs/openhim-console/default-local.json:/usr/share/nginx/html/config/default.json
healthcheck:
test: "curl -sS http://openhim-console || exit 1"
interval: 10s
timeout: 60s
retries: 3
# Loads Default OpenHIM Config
openhim-config:
container_name: openhim-config
image: ghcr.io/i-tech-uw/openhim-config:v0.0.0
volumes:
- ./configs/openhim/test-openhim-config.json:/app/test-openhim-config.json
###
# OpenCR - Client Registry
###
opencr:
container_name: opencr
hostname: opencr
image: intrahealth/opencr:15a3465
restart: unless-stopped
environment:
- NODE_ENV=docker
- HAPI_FHIR_URL=http://opencr-fhir:8080/fhir/metadata
volumes:
- ./configs/opencr/config.json:/src/server/config/config_docker.json
- ./configs/opencr/mediator.json:/src/server/config/mediator.json
- ./configs/opencr/decisionRules.json:/src/server/config/decisionRules.json
- ./configs/opencr/PatientRelationship.json:/src/resources/Relationships/PatientRelationship.json
ports:
- 3000:3000
depends_on:
- opencr-fhir
opencr-fhir:
image: hapiproject/hapi:v5.1.0
container_name: opencr-fhir
hostname: opencr-fhir
restart: unless-stopped
healthcheck:
test: "curl -sS http://opencr-fhir:8080/fhir/metadata || exit 1"
interval: 90s
timeout: 30s
retries: 3
volumes:
- /data/hapi
# - ./configs/opencr/application.yml:/data/hapi/application.yaml
ports:
- 8081:8080
# env_file:
# - ./configs/opencr/.env
# environment:
# SPRING_CONFIG_LOCATION: 'file:///data/hapi/application.yaml'
es:
container_name: es
hostname: es
image: intrahealth/elasticsearch:adf8905
restart: unless-stopped
environment:
- xpack.security.enabled=false
- discovery.type=single-node
ulimits:
nofile:
soft: 65536
hard: 65536
volumes:
- /usr/share/elasticsearch/data
healthcheck:
test: "curl --silent --fail http://es:9200/_cluster/health || exit 1"
# Hapi-FHIR - SHR
shr-hapi-fhir:
container_name: shr-hapi-fhir
image: hapiproject/hapi:v5.5.1
ports:
- "8082:8080"
restart: always
environment:
- spring.datasource.url=jdbc:postgresql://db/hapi?targetServerType=primary
- spring.datasource.username=admin
- spring.datasource.password=admin
- spring.datasource.driverClassName=org.postgresql.Driver
- spring.jpa.properties.hibernate.dialect=org.hibernate.dialect.PostgreSQL95Dialect
- spring.datasource.hikari.minimumIdle=20
- spring.datasource.hikari.connectionTimeout=60000
- spring.datasource.hikari.idleTimeout=600000
- hapi.fhir.allow_external_references=true
- hapi.fhir.bulk_export_enabled=true
- hapi.fhir.enable_repository_validating_interceptor=true
depends_on:
- db
# Streaming Pipeline
streaming-pipeline:
image: openmrsinfra/openmrs-fhir-analytics:plir-binlog
container_name: streaming-pipeline
healthcheck:
test: "exit 0"
depends_on:
sigdep3:
condition: service_healthy
volumes:
- ./configs/streaming-pipeline/config.json:/deployments/config.json
# data is the directory which you want to persist the generated parquet files
# - ./configs/streaming-pipeline/parquet:/tmp
environment:
- OPENMRS_URL=http://sigdep3:8080/openmrs
- OPENMRS_USERNAME=admin
- OPENMRS_PASSWORD=Admin123
- SINK_URL=http://openhim-core:5001/fhir/
- SINK_USERNAME=dbezium
- SINK_PASSWORD=dbezium
- JDBC_FETCH_SIZE=10000
- JDBC_MAX_POOL_SIZE=50
- JDBC_INITIAL_POOL_SIZE=10
- JDBC_DRIVER_CLASS=com.mysql.cj.jdbc.Driver
- JDBC_URL=jdbc:mysql://sigdep-db:3306/openmrs
# the 2 variable below should be same as volume mappings above
#- PARQUET_PATH=
- FHIR_DEBEZIUM_CONFIG_PATH=/deployments/config.json
#DB for HAPI FHIR for SHR
db:
image: postgres
restart: always
environment:
POSTGRES_PASSWORD: admin
POSTGRES_USER: admin
POSTGRES_DB: hapi
volumes:
- /var/lib/postgresql/data
ports:
- "5432:5432"
volumes:
db-data:
key_trust-store-volume: