-
Notifications
You must be signed in to change notification settings - Fork 3
/
docker-compose_image_based.yml
110 lines (105 loc) · 3.59 KB
/
docker-compose_image_based.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
version: '3.8'
networks:
operandi:
name: operandi
driver: bridge
driver_opts:
com.docker.network.driver.mtu: 1450
services:
operandi-rabbitmq:
image: "rabbitmq:3.12-management"
container_name: operandi-rabbitmq
hostname: rabbit-mq-host
ports:
- "5672:5672"
- "15672:15672"
- "25672:25672"
volumes:
- "/rabbitmq-data/etc/:/var/etc/rabbitmq/"
- "/rabbitmq-data/data/:/var/lib/rabbitmq/"
- "/rabbitmq-data/log/:/var/log/rabbitmq/"
- type: bind
source: ${OPERANDI_RABBITMQ_CONFIG_JSON}
target: /rmq_definitions.json
environment:
- RABBITMQ_SERVER_ERL_ARGS=-rabbitmq_management load_definitions "/rmq_definitions.json"
- RABBITMQ_FEATURE_FLAGS=quorum_queue,implicit_default_bindings,classic_mirrored_queue_version
networks:
- operandi
healthcheck:
test: rabbitmq-diagnostics check_port_connectivity
interval: 1s
timeout: 5s
retries: 120
operandi-mongodb:
image: "mongo"
container_name: operandi-mongodb
hostname: mongo-db-host
ports:
- "27017:27017"
volumes:
- "/operandi-mongodb:/data/db"
environment:
MONGO_INITDB_ROOT_USERNAME: ${OPERANDI_DB_ROOT_USER}
MONGO_INITDB_ROOT_PASSWORD: ${OPERANDI_DB_ROOT_PASS}
networks:
- operandi
healthcheck:
test: echo 'db.runCommand("ping").ok' | mongosh localhost:27017/test --quiet
interval: 1s
timeout: 5s
retries: 120
operandi-server:
image: ghcr.io/subugoe/operandi-server:main
container_name: operandi-server
depends_on:
operandi-rabbitmq:
condition: service_healthy
operandi-mongodb:
condition: service_healthy
restart: on-failure
ports:
- "80:8000"
environment:
- OPERANDI_DB_NAME=${OPERANDI_DB_NAME}
- OPERANDI_DB_URL=${OPERANDI_DB_URL}
- OPERANDI_HARVESTER_DEFAULT_USERNAME=${OPERANDI_HARVESTER_DEFAULT_USERNAME}
- OPERANDI_HARVESTER_DEFAULT_PASSWORD=${OPERANDI_HARVESTER_DEFAULT_PASSWORD}
- OPERANDI_LOGS_DIR=${OPERANDI_LOGS_DIR}
- OPERANDI_RABBITMQ_URL=${OPERANDI_RABBITMQ_URL}
- OPERANDI_SERVER_BASE_DIR=${OPERANDI_SERVER_BASE_DIR}
- OPERANDI_SERVER_DEFAULT_USERNAME=${OPERANDI_SERVER_DEFAULT_USERNAME}
- OPERANDI_SERVER_DEFAULT_PASSWORD=${OPERANDI_SERVER_DEFAULT_PASSWORD}
- OPERANDI_SERVER_URL_LIVE=${OPERANDI_SERVER_URL_LIVE}
- OPERANDI_SERVER_URL_LOCAL=${OPERANDI_SERVER_URL_LOCAL}
volumes:
- "${OPERANDI_LOGS_DIR}:${OPERANDI_LOGS_DIR}"
- "${OPERANDI_SERVER_BASE_DIR}:${OPERANDI_SERVER_BASE_DIR}"
networks:
- operandi
command: operandi-server start
operandi-broker:
image: ghcr.io/subugoe/operandi-broker:main
container_name: operandi-broker
depends_on:
operandi-rabbitmq:
condition: service_healthy
operandi-mongodb:
condition: service_healthy
restart: on-failure
environment:
- OPERANDI_DB_NAME=${OPERANDI_DB_NAME}
- OPERANDI_DB_URL=${OPERANDI_DB_URL}
- OPERANDI_HPC_PROJECT_NAME=${OPERANDI_HPC_PROJECT_NAME}
- OPERANDI_HPC_PROJECT_USERNAME=${OPERANDI_HPC_PROJECT_USERNAME}
- OPERANDI_HPC_SSH_KEYPATH=/home/root/.ssh/gwdg_hpc_key
- OPERANDI_LOGS_DIR=${OPERANDI_LOGS_DIR}
- OPERANDI_RABBITMQ_URL=${OPERANDI_RABBITMQ_URL}
volumes:
- "/var/run/docker.sock:/var/run/docker.sock"
- "${OPERANDI_LOGS_DIR}:${OPERANDI_LOGS_DIR}"
- "${OPERANDI_SERVER_BASE_DIR}:${OPERANDI_SERVER_BASE_DIR}"
- "${OPERANDI_HPC_SSH_KEYPATH}:/home/root/.ssh/gwdg_hpc_key"
networks:
- operandi
command: operandi-broker start