forked from UoMResearchIT/Galaxy-Show-And-Tell
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdocker-compose.yml
179 lines (170 loc) · 4.96 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
secrets:
GALAXY_STORAGE_PASSWORD:
file: ./galaxy/secrets/GALAXY_STORAGE_PASSWORD
services:
nginx:
image: nginx
container_name: ${PROJECT_NAME}-nginx
restart: unless-stopped
depends_on:
- galaxy
volumes:
- galaxy-store:/galaxy/server/
- ./nginx/galaxy.conf:/etc/nginx/conf.d/default.conf:ro
- ./galaxy/config/welcome.html:/galaxy/server/static/welcome.html
ports:
- "80:80"
networks:
- galaxy
galaxy:
image: galaxy/galaxy-min:24.2.2
restart: unless-stopped
group_add:
- ${DOCKER_GID}
depends_on:
galaxy-postgres:
condition: service_healthy
rabbitmq:
condition: service_healthy
container_name: ${PROJECT_NAME}-galaxy
volumes:
# Persistant storage for Galaxy
- galaxy-store:/galaxy/server/
- file-store:/file-store
# TUSD binary
- ./galaxy/tusd:/usr/local/sbin/tusd
# Populate the instance
- ./galaxy/init/bootstrap.py:/galaxy/server/bootstrap.py
- ./galaxy/tools:/galaxy/server/tools/
# Add custom configuration files
- ./galaxy/config/galaxy.yml:/galaxy/server/config/galaxy.yml
- ./galaxy/config/tool_conf.xml:/galaxy/server/config/tool_conf.xml.sample
- ./galaxy/config/job_conf.xml:/galaxy/server/config/job_conf.xml
- ./galaxy/config/datatypes_conf.xml:/galaxy/server/config/datatypes_conf.xml
- ./galaxy/config/file_sources_conf.yml:/galaxy/server/config/file_sources_conf.yml
# Provide docker-in-docker
- /usr/bin/docker:/usr/bin/docker
- /var/run/docker.sock:/var/run/docker.sock:ro
networks:
- galaxy
command: ["sh", "-c", "pip install --upgrade s3fs botocore boto3 && exec galaxy"]
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:8080"]
interval: 30s
timeout: 30s
retries: 5
galaxy-bootstrap:
image: galaxy/galaxy-min:24.1.3
container_name: ${PROJECT_NAME}-galaxy-bootstrap
environment:
- GALAXY_URL=http://${PROJECT_NAME}-galaxy:8080
- GALAXY_API_KEY=${GALAXY_API_KEY}
- GALAXY_ADMIN_USERNAME=${GALAXY_ADMIN_USER}
- GALAXY_ADMIN_EMAIL=${GALAXY_ADMIN_EMAIL}
- GALAXY_ADMIN_PASSWORD=${GALAXY_ADMIN_PASS}
depends_on:
galaxy:
condition: service_healthy
volumes:
- ./galaxy/init/bootstrap.py:/bootstrap.py
- ./galaxy/workflows:/galaxy-workflows
networks:
- galaxy
entrypoint: ["python"]
command: ["/bootstrap.py"]
galaxy-postgres:
container_name: ${PROJECT_NAME}-galaxy-postgres
image: postgres
restart: unless-stopped
secrets: [GALAXY_STORAGE_PASSWORD]
ports:
- 5432:5432
environment:
POSTGRES_USER: galaxy
POSTGRES_PASSWORD_FILE: /run/secrets/GALAXY_STORAGE_PASSWORD
POSTGRES_DB: galaxy
networks:
- galaxy
healthcheck:
test: ["CMD-SHELL", "pg_isready -U galaxy"]
interval: 5s
timeout: 5s
retries: 5
rabbitmq:
image: docker.io/bitnami/rabbitmq:3.12
container_name: ${PROJECT_NAME}-rabbitmq
restart: unless-stopped
ports:
- '1883:1883'
- '5672:5672'
- '15672:15672'
environment:
- RABBITMQ_SECURE_PASSWORD=yes
- RABBITMQ_USERNAME=rabbitmq
- RABBITMQ_PASSWORD=rabbitmq
- RABBITMQ_MANAGEMENT_ALLOW_WEB_ACCESS=yes
- RABBITMQ_PLUGINS=rabbitmq_mqtt,rabbitmq_management
- RABBITMQ_DISK_FREE_RELATIVE_LIMIT=1.0
- RABBITMQ_DISK_FREE_ABSOLUTE_LIMIT=500MB
#- RABBITMQ_LOGS=-
volumes:
- rabbitmq_data:/bitnami/rabbitmq/mnesia
#- ./config/rabbit/advanced.config:/bitnami/rabbitmq/conf/advanced.config:ro
networks:
- galaxy
healthcheck:
test: ["CMD", "rabbitmq-diagnostics", "ping"]
interval: 10s
timeout: 5s
retries: 5
minio:
image: minio/minio
container_name: ${PROJECT_NAME}-minio
restart: unless-stopped
ports:
- "9000:9000"
- "9001:9001"
environment:
MINIO_ROOT_USER: minioadmin
MINIO_ROOT_PASSWORD: miniogalaxy
MINIO_ACCESS_KEY: miniogalaxy
MINIO_SECRET_KEY: miniogalaxy
volumes:
- minio-data:/data
command: server /data --console-address ":9001"
networks:
- galaxy
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:9000/minio/health/live"]
interval: 30s
timeout: 30s
retries: 5
minio-bootstrap:
image: minio/mc
container_name: ${PROJECT_NAME}-minio-bootstrap
depends_on:
minio:
condition: service_healthy
volumes:
- ./minio/init/bootstrap.sh:/bootstrap.sh
networks:
- galaxy
entrypoint: >-
sh -c "
echo 'Bootstraping Minio...';
mc alias set minio http://minio:9000 minioadmin miniogalaxy;
mc mb minio/galaxy;
mc mb minio/galaxy-backend;
exit 0;
"
networks:
galaxy:
volumes:
galaxy-store:
name: galaxy-store
file-store:
name: file-store
rabbitmq_data:
name: rabbitmq-data
minio-data:
name: minio-data