-
Notifications
You must be signed in to change notification settings - Fork 25
/
docker-compose.yml
411 lines (394 loc) · 10.6 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
# an ephemeral instance of ChRIS backend services for local development
#
# warning: /var/run/docker.sock is mounted into some services (notably pman)
services:
chrisomatic:
image: ghcr.io/fnndsc/chrisomatic:1.0.0
profiles:
- tools
volumes:
- "./chrisomatic.yml:/chrisomatic.yml:ro"
- "/var/run/docker.sock:/var/run/docker.sock:rw"
userns_mode: host
depends_on:
- chris
networks:
- local
db_migrate:
image: ghcr.io/fnndsc/cube:5.0.0
command: python manage.py migrate --noinput
env_file: secrets.env
volumes:
- chris_files:/data:rw
depends_on:
db:
condition: service_healthy
networks:
- local
chris:
container_name: chris
image: ghcr.io/fnndsc/cube:5.0.0
ports:
- "8000:8000"
volumes:
- chris_files:/data:rw
depends_on:
db_migrate:
condition: service_completed_successfully
queue:
condition: service_started
cube-nonroot-user-volume-fix:
condition: service_completed_successfully
networks:
- local
env_file: secrets.env
labels:
org.chrisproject.role: "ChRIS_ultron_backEnd"
org.chrisproject.miniChRIS: "miniChRIS"
worker:
image: ghcr.io/fnndsc/cube:5.0.0
command: celery -A core worker -c 4 -l info -Q main1,main2
volumes:
- chris_files:/data:rw
env_file: secrets.env
depends_on:
db_migrate:
condition: service_completed_successfully
queue:
condition: service_started
pfcon:
condition: service_started
cube-nonroot-user-volume-fix:
condition: service_completed_successfully
restart: unless-stopped
networks:
- local
worker_periodic:
image: ghcr.io/fnndsc/cube:5.0.0
command: celery -A core worker -c 2 -l info -Q periodic
volumes:
- chris_files:/data:rw
env_file: secrets.env
depends_on:
db_migrate:
condition: service_completed_successfully
queue:
condition: service_started
cube-nonroot-user-volume-fix:
condition: service_completed_successfully
restart: unless-stopped
networks:
- local
scheduler:
image: ghcr.io/fnndsc/cube:5.0.0
command: celery -A core beat -l info --scheduler django_celery_beat.schedulers:DatabaseScheduler
volumes:
- chris_files:/data:rw
env_file: secrets.env
depends_on:
db_migrate:
condition: service_completed_successfully
queue:
condition: service_started
cube-nonroot-user-volume-fix:
condition: service_completed_successfully
restart: unless-stopped
networks:
- local
db:
image: docker.io/library/postgres:16
env_file: secrets.env
restart: unless-stopped
volumes:
- db_data:/var/lib/postgresql/data
networks:
- local
healthcheck:
test: ["CMD", "pg_isready"]
interval: 2s
timeout: 4s
retries: 3
start_period: 60s
queue:
image: docker.io/library/rabbitmq:3
restart: on-failure
networks:
- local
pfcon:
container_name: pfcon
image: ghcr.io/fnndsc/pfcon:5.2.2
environment:
COMPUTE_SERVICE_URL: http://pman:5010/api/v1/
SECRET_KEY: secret
PFCON_USER: pfcon
PFCON_PASSWORD: pfcon1234
PFCON_INNETWORK: "true"
STORAGE_ENV: filesystem
STOREBASE_MOUNT: /var/local/storeBase
ports:
- "5005:5005"
volumes:
- chris_files:/var/local/storeBase
networks:
local:
aliases:
- pfcon.host
remote:
labels:
org.chrisproject.role: "pfcon"
user: "1001"
depends_on:
cube-nonroot-user-volume-fix:
condition: service_completed_successfully
pman:
image: ghcr.io/fnndsc/pman:6.2.0
container_name: pman
environment:
CONTAINER_ENV: docker
CONTAINER_USER: "1001:"
ENABLE_HOME_WORKAROUND: "yes"
JOB_LABELS: "org.chrisproject.miniChRIS=plugininstance"
SECRET_KEY: secret
REMOVE_JOBS: "yes"
volumes:
- /var/run/docker.sock:/var/run/docker.sock:rw
depends_on:
# see https://github.com/FNNDSC/pman/blob/v6.2.0/README.md#how-storage-works
- pfcon
ports:
- "5010:5010"
networks:
remote:
userns_mode: "host"
labels:
org.chrisproject.role: "pman"
chris_ui:
image: ghcr.io/fnndsc/chris_ui:20240507.446-767958ca
command: sirv --host --single
environment:
REACT_APP_CHRIS_UI_URL: http://localhost:8000/api/v1/
REACT_APP_PFDCM_URL: http://localhost:4005/
ports:
- "8020:3000"
orthanc:
image: docker.io/jodogne/orthanc-plugins:1.12.3
volumes:
- ./orthanc.json:/etc/orthanc/orthanc.json:ro
- orthanc:/var/lib/orthanc/db
ports:
- "4242:4242"
- "8042:8042"
networks:
- pacs
profiles:
- pacs
- orthanc
pfdcm:
image: ghcr.io/fnndsc/pfdcm:3.1.2
container_name: pfdcm
environment:
MAX_WORKERS: 1
volumes:
- pfdcm:/home/dicom:rw
- ./pfdcm-services:/home/dicom/services:ro
- chris_files:/chris_files:rw
ports:
- "4005:4005"
networks:
- pacs
user: "1001"
profiles:
- pacs
depends_on:
pfdcm-nonroot-user-volume-fix:
condition: service_completed_successfully
oxidicom:
image: ghcr.io/fnndsc/oxidicom:2.0.0
environment:
OXIDICOM_DB_CONNECTION: postgresql://chris:chris1234@db:5432/chris
OXIDICOM_FILES_ROOT: /data
OXIDICOM_SCP_AET: ChRIS
OXIDICOM_PACS_ADDRESS: '{MINICHRISORTHANC="orthanc:4242"}'
OXIDICOM_SCP_PROMISCUOUS: "true"
OXIDICOM_DB_BATCH_SIZE: 20
OXIDICOM_LISTENER_THREADS: 32
OXIDICOM_VERBOSE: "true"
OXIDICOM_LISTENER_PORT: 11111
ports:
- "11111:11111"
volumes:
- chris_files:/data:rw
networks:
- pacs
- local
profiles:
- pacs
user: 1001:0
depends_on:
cube-nonroot-user-volume-fix:
condition: service_completed_successfully
pfbridge:
image: docker.io/fnndsc/pfbridge:3.7.2
container_name: pfbridge
environment:
MAX_WORKERS: 1
PFLINK_USERNAME: pflink
PFLINK_PASSWORD: pflink1234
NAME: PFDCMLOCAL
PACSNAME: orthanc
CUBEANDSWIFTKEY: local
ports:
- "33333:33333"
networks:
local:
pflink:
profiles:
- pflink
pflink:
image: docker.io/fnndsc/pflink:settings-39e91ed
container_name: pflink
restart: unless-stopped
environment:
PFDCM_NAME: "NOTPFDCMLOCAL" # work around for hard-coded edge case
PFLINK_MONGODB: "mongodb://pflink-db:27017"
PFLINK_PFDCM: "http://pfdcm:4005"
PFLINK_PORT: "4010"
ports:
- "4010:4010"
networks:
local:
pflink:
depends_on:
- pflink-db
profiles:
- pflink
pflink-db:
image: mongo
environment:
- PUID=1000
- PGID=1000
volumes:
- pflink-db-data:/data/db
restart: unless-stopped
networks:
pflink:
profiles:
- pflink
graphql-engine:
image: docker.io/hasura/graphql-engine:v2.40.0
ports:
- "8090:8080"
restart: unless-stopped
environment:
## postgres database to store Hasura metadata
HASURA_GRAPHQL_METADATA_DATABASE_URL: postgres://hasura:hasura1234@hasura-db:5432/hasura
## enable the console served by server
HASURA_GRAPHQL_ENABLE_CONSOLE: "true" # set to "false" to disable console
## enable debugging mode. It is recommended to disable this in production
HASURA_GRAPHQL_DEV_MODE: "true"
HASURA_GRAPHQL_ENABLED_LOG_TYPES: startup, http-log, webhook-log, websocket-log, query-log
## uncomment next line to run console offline (i.e load console assets from server instead of CDN)
HASURA_GRAPHQL_CONSOLE_ASSETS_DIR: /srv/console-assets
## uncomment next line to set an admin secret
# HASURA_GRAPHQL_ADMIN_SECRET: myadminsecretkey
HASURA_GRAPHQL_METADATA_DEFAULTS: '{"backend_configs":{"dataconnector":{"athena":{"uri":"http://data-connector-agent:8081/api/v1/athena"},"mariadb":{"uri":"http://data-connector-agent:8081/api/v1/mariadb"},"mysql8":{"uri":"http://data-connector-agent:8081/api/v1/mysql"},"oracle":{"uri":"http://data-connector-agent:8081/api/v1/oracle"},"snowflake":{"uri":"http://data-connector-agent:8081/api/v1/snowflake"}}}}'
depends_on:
hasura-db:
condition: service_healthy
data-connector-agent:
condition: service_healthy
networks:
local:
profiles:
- hasura
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:8080/healthz?strict=false"]
interval: 5s
timeout: 10s
retries: 5
start_period: 5s
data-connector-agent:
image: hasura/graphql-data-connector:v2.40.0
restart: unless-stopped
ports:
- 8081:8081
environment:
QUARKUS_LOG_LEVEL: ERROR # FATAL, ERROR, WARN, INFO, DEBUG, TRACE
## https://quarkus.io/guides/opentelemetry#configuration-reference
QUARKUS_OPENTELEMETRY_ENABLED: "false"
## QUARKUS_OPENTELEMETRY_TRACER_EXPORTER_OTLP_ENDPOINT: http://jaeger:4317
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:8081/api/v1/athena/health"]
interval: 5s
timeout: 10s
retries: 5
start_period: 5s
networks:
local:
profiles:
- hasura
hasura-db:
image: docker.io/library/postgres:15
restart: unless-stopped
volumes:
- hasura-db-data:/var/lib/postgresql/data
environment:
POSTGRES_USER: hasura
POSTGRES_PASSWORD: hasura1234
POSTGRES_DB: hasura
networks:
local:
profiles:
- hasura
healthcheck:
test: ["CMD", "pg_isready"]
interval: 2s
timeout: 4s
retries: 3
start_period: 60s
hasura-cli:
image: ghcr.io/fnndsc/hasura-cli:2.41.0
command: hasura metadata apply
restart: "no"
volumes:
- ./hasura:/hasura:ro
working_dir: /hasura
networks:
local:
profiles:
- hasura
depends_on:
graphql-engine:
condition: service_healthy
# Non-root container user workarounds
cube-nonroot-user-volume-fix:
image: docker.io/library/alpine:latest
volumes:
- chris_files:/data:rw
user: root
command: chmod g+rwx /data
restart: "no"
pfdcm-nonroot-user-volume-fix:
image: docker.io/library/alpine:latest
volumes:
- pfdcm:/home/dicom:rw
user: root
command: chown 1001 /home/dicom
restart: "no"
networks:
local:
name: minichris-local
remote:
pacs:
monitoring:
pflink:
volumes:
chris_files:
name: minichris-files
db_data:
orthanc:
pfdcm:
grafana_data:
openobserve_data:
pflink-db-data:
hasura-db-data: