-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathdocker-compose.yml
143 lines (139 loc) · 3.54 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
version: "3.3"
services:
rabbitmq:
image: shipai/boa-rabbitmq
build:
dockerfile: scripts/rabbitmq.dockerfile
context: .
environment:
- RABBITMQ_DEFAULT_USER=${RABBITMQ_USERNAME}
- RABBITMQ_DEFAULT_PASS=${RABBITMQ_PASSWORD}
ports:
- "15672:15672"
worker-gpu:
image: shipai/boa-task-gpu
runtime: nvidia
build:
dockerfile: scripts/task_gpu.dockerfile
context: .
args:
- GIT_VERSION=${GIT_VERSION}
- PACKAGE_VERSION=${PACKAGE_VERSION}
environment:
- NVIDIA_VISIBLE_DEVICES=${NVIDIA_ID}
- CELERY_BROKER
- ORTHANC_URL
- ORTHANC_PORT
- ORTHANC_USERNAME
- ORTHANC_PASSWORD
- POSTGRES_HOST
- POSTGRES_PORT
- POSTGRES_USER
- POSTGRES_PASSWORD
- POSTGRES_DATABASE
- PREDICT_FAST
# Output vars
- PATIENT_INFO_IN_OUTPUT
- SMB_DIR_OUTPUT
- SMB_USER
- SMB_PWD
- SEGMENTATION_UPLOAD_URL
- UPLOAD_USER
- UPLOAD_PWD
restart: always
user: ${DOCKER_USER}
deploy:
resources:
limits:
cpus: '5'
shm_size: 1g
ulimits:
memlock: -1
stack: 67108864
volumes:
- /etc/passwd:/etc/passwd:ro
- /etc/group:/etc/group:ro
- ${SEGMENTATION_DIR}:/storage_directory
- ${LOCAL_WEIGHTS_PATH}:/app/weights
command: ["python", "-m", "celery", "--app", "celery_task", "worker", "--concurrency=1", "--loglevel=INFO", "-P", "threads"]
depends_on:
- rabbitmq
worker:
image: shipai/boa-task
build:
dockerfile: scripts/task.dockerfile
context: .
args:
- GIT_VERSION=${GIT_VERSION}
- PACKAGE_VERSION=${PACKAGE_VERSION}
environment:
- CELERY_BROKER
- ORTHANC_URL
- ORTHANC_PORT
- ORTHANC_USERNAME
- ORTHANC_PASSWORD
- TRITON_URL
- POSTGRES_HOST
- POSTGRES_PORT
- POSTGRES_USER
- POSTGRES_PASSWORD
- POSTGRES_DATABASE
- PREDICT_FAST
# Output vars
- PATIENT_INFO_IN_OUTPUT
- SEGMENTATION_UPLOAD_URL
- UPLOAD_USER
- UPLOAD_PWD
- SMB_DIR_OUTPUT
- SMB_USER
- SMB_PWD
restart: always
user: ${DOCKER_USER}
deploy:
resources:
limits:
cpus: '5'
volumes:
- /etc/passwd:/etc/passwd:ro
- /etc/group:/etc/group:ro
- ${SEGMENTATION_DIR}:/storage_directory
- ${LOCAL_WEIGHTS_PATH}:/app/weights
command: [ "python", "-m", "celery", "--app", "celery_task", "worker", "--concurrency=1", "--loglevel=INFO", "-P", "threads" ]
depends_on:
- rabbitmq
orthanc:
image: shipai/boa-orthanc
build:
dockerfile: scripts/orthanc.dockerfile
context: .
args:
- GIT_VERSION=${GIT_VERSION}
- PACKAGE_VERSION=${PACKAGE_VERSION}
environment:
- CELERY_BROKER
- POSTGRES_HOST
- POSTGRES_PORT
- POSTGRES_USER
- POSTGRES_PASSWORD
- POSTGRES_DATABASE
- |
ORTHANC__REGISTERED_USERS=
{"${ORTHANC_USERNAME}": "${ORTHANC_PASSWORD}"}
restart: always
ports:
- "4242:4242"
- "${ORTHANC_PORT}:8042"
volumes:
- /tmp/orthanc-db/:/var/lib/orthanc/db/
monitoring:
image: postgres:latest
environment:
POSTGRES_USER: ${POSTGRES_USER}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
POSTGRES_DB: ${POSTGRES_DATABASE}
POSTGRES_HOST_AUTH_METHOD: trust
ports:
- "5433:5432"
volumes:
- ${POSTGRES_DATA}:/var/lib/postgresql/data
- ./init.sql:/docker-entrypoint-initdb.d/init.sql