-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
370 lines (363 loc) · 10.5 KB
/
docker-compose.yml
File metadata and controls
370 lines (363 loc) · 10.5 KB
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
x-logging: &default-logging
driver: "json-file"
options:
max-size: "50m"
max-file: "6"
services:
catalystexplorer.com:
build:
context: "./docker"
dockerfile: Dockerfile.dev
args:
WWWGROUP: "${WWWGROUP:-1000}"
deploy:
resources:
limits:
memory: ${DOCKER_COMPOSE_MEMORY_LIMIT:-2048M}
cpus: "1.0"
image: catalystexplorer
container_name: catalystexplorer.com
tty: true
restart: unless-stopped
env_file:
- ./application/.env
extra_hosts:
- "host.docker.internal:host-gateway"
ports:
- "${APP_PORT:-80}:8000"
- "${APP_SSL_PORT:-443}:443"
- "${APP_SSL_PORT:-443}:443/udp"
- "${VITE_PORT:-5173}:${VITE_PORT:-5173}"
environment:
CONTAINER_ROLE: "app"
CADDY_SERVER_SERVER_NAME: "${CADDY_SERVER_SERVER_NAME:-localhost:8000}"
CADDY_SERVER_TLS_CONFIG: "${CADDY_SERVER_TLS_CONFIG:-}"
FRANKENPHP_PORT: "${FRANKENPHP_PORT:-8000}"
IGNITION_LOCAL_SITES_PATH: "${PWD}"
LARAVEL_SAIL: 1
PHP_OPCACHE_ENABLE: 0
NODE_OPTIONS: "${NODE_OPTIONS:---max-old-space-size=8096}"
OCTANE_WATCH: "${OCTANE_WATCH:-true}"
WWWGROUP: "${WWWUSER:-1000}"
WWWUSER: "${WWWUSER:-1000}"
XDEBUG_MODE: "${SAIL_XDEBUG_MODE:-off}"
XDEBUG_CONFIG: "${SAIL_XDEBUG_CONFIG:-client_host=host.docker.internal}"
XDG_CONFIG_HOME: /var/www/caddy
XDG_DATA_HOME: /var/www/caddy
volumes:
- ./application:/var/www
- ./docker/scripts:/scripts
- ./docker/certs:/etc/caddy/certs:ro
- ./data/app/data:/data
networks:
- catalystexplorer-net
- shared-network
depends_on:
- catalystexplorer.db
- catalystexplorer-search
- catalystexplorer.redis
catalystexplorer.cardanonode:
container_name: catalystexplorer.cardanonode
image: ghcr.io/intersectmbo/cardano-node:10.1.4
command:
[
"run",
"--config",
"/config/config.json",
"--database-path",
"/data/db",
"--socket-path",
"/ipc/node.socket",
"--topology",
"/config/topology.json",
]
volumes:
- ./cardanonode/config/network/${CARDANO_NETWORK:-preview}/cardano-node:/config
- ./cardanonode/config/network/${CARDANO_NETWORK:-preview}/genesis:/genesis
- node-db:/data
- node-ipc:/ipc
restart: on-failure
environment:
CARDANO_NODE_SOCKET_PATH: /ipc/node.socket
healthcheck:
test: ["CMD", "stat", "/ipc/node.socket"]
interval: 30s
timeout: 10s
retries: 3
networks:
- catalystexplorer-net
- shared-network
profiles:
- cardano
catalystexplorer.cardanodb:
container_name: catalystexplorer.cardanodb
image: postgres:16.3-alpine3.19
environment:
- POSTGRES_LOGGING=true
- POSTGRES_DB=${POSTGRES_DB:-carp_preview} # dynamic based on network, default to carp_preview
- POSTGRES_USER=${PGUSER:-carp}
- POSTGRES_PASSWORD=${PGPASSWORD:-v8hlDV0yMAHHlIurYupj}
- PGPASSFILE=/run/secrets/.pgpass
secrets:
- source: pgpass
target: .pgpass
ports:
- ${POSTGRES_PORT:-5434}:5434 # Expose the database on a different port
volumes:
- carp-db-data:/var/lib/postgresql/data
restart: on-failure
networks:
- catalystexplorer-net
- shared-network
healthcheck:
test: ["CMD-SHELL", "pg_isready -U carp -d carp_preview -p 5434"]
interval: 10s
timeout: 5s
retries: 5
command: >
postgres -c port=5434 ${POSTGRES_ARGS:--c maintenance_work_mem=1GB -c max_parallel_maintenance_workers=4}
profiles:
- cardano
catalystexplorer.adminer:
image: adminer:4.8.1
container_name: catalystexplorer.adminer
restart: unless-stopped
ports:
- 8080:8080
networks:
- catalystexplorer-net
- shared-network
profiles:
- testing
catalystexplorer.queue:
image: catalystexplorer
container_name: catalystexplorer.queue
tty: true
depends_on:
- catalystexplorer.db
- catalystexplorer.redis
env_file:
- ./application/.env
environment:
APP_SETUP: "true"
CONTAINER_ROLE: "queue"
DB_CONNECTION: pgsql
MEDIA_DISK: public
MEILISEARCH_KEY: v8hlDV0yMAHHlIurYupj
MEILISEARCH_HOST: "http://catalystexplorer-search:7700"
PHP_OPCACHE_ENABLE: 0
PHP_OPCACHE_VALIDATE_TIMESTAMPS: 0
PHP_MEMORY_LIMIT: 2048M
POSTGRESQL_DB_SYNC_DB_HOST: postgres_dbsync
POSTGRESQL_DB_SYNC_PASSWORD: v8hlDV0yMAHHlIurYupj
POSTGRESQL_DB_SYNC_DB: cexplorer
POSTGRESQL_DB_SYNC_USER: postgres
POSTGRESQL_WEB_DB_HOST: catalystexplorer.db
POSTGRESQL_WEB_DB: catalystexplorer
POSTGRESQL_WEB_USER: explorerdbuser
POSTGRESQL_WEB_PASSWORD: ASLJ023470AlserLFH
TELESCOPE_USE_DARK_THEME: "true"
XDG_CONFIG_HOME: /var/www
build:
context: ./docker
args: {}
dockerfile: ./Dockerfile.dev
volumes:
# - type: volume
# source: node-ipc
# target: /ipc
# volume:
# nocopy: true
- ./application:/var/www:cached
networks:
- catalystexplorer-net
- shared-network
# database
catalystexplorer.db:
image: pgvector/pgvector:pg18-trixie
container_name: catalystexplorer.db
logging: *default-logging
ports:
- "${FORWARD_DB_PORT:-5432}:5432"
environment:
- POSTGRES_LOGGING=true
- POSTGRES_DB=catalystexplorer
- POSTGRES_PASSWORD=ASLJ023470AlserLFH
- POSTGRES_USER=explorerdbuser
- POSTGRES_POSTGRES_PASSWORD=${POSTGRES_POSTGRES_PASSWORD:-alj2340aaALJAF2341408AUUZLJK}
volumes:
- "catalystexplorer-db:/var/lib/postgresql"
networks:
- catalystexplorer-net
- shared-network
healthcheck:
test:
- CMD
- pg_isready
- "-q"
- "-d"
- "catalystexplorer"
- "-U"
- "explorerdbuser"
retries: 3
timeout: 5s
# one-shot init to enable extensions in explorerweb
catalystexplorer.db-init:
image: postgres:18.1-trixie
container_name: catalystexplorer.db-init
depends_on:
- catalystexplorer.db
networks:
- catalystexplorer-net
entrypoint: ["/bin/sh","-c"]
command: >
"until pg_isready -h catalystexplorer.db -U explorerdbuser -d catalystexplorer; do echo waiting for db; sleep 1; done;
PGPASSWORD=${POSTGRES_POSTGRES_PASSWORD:-alj2340aaALJAF2341408AUUZLJK} psql -h catalystexplorer.db -U postgres -d catalystexplorer -v ON_ERROR_STOP=1 -c 'CREATE EXTENSION IF NOT EXISTS vector';
echo 'pgvector enabled';"
restart: "no"
# meilisearch
catalystexplorer-search:
image: getmeili/meilisearch:v1.35.0
container_name: catalystexplorer-search
logging: *default-logging
ports:
- "${FORWARD_MEILISEARCH_PORT:-7700}:7700"
environment:
MEILI_NO_ANALYTICS: "${MEILISEARCH_NO_ANALYTICS:-false}"
MEILISEARCH_KEY: v8hlDV0yMAHHlIurYupj
volumes:
- "catalystexplorer-search:/meili_data"
networks:
- catalystexplorer-net
healthcheck:
test:
- CMD
- wget
- "--no-verbose"
- "--spider"
- "http://127.0.0.1:7700/health"
retries: 3
timeout: 5s
# redis
catalystexplorer.redis:
image: redis:8.0-M02-alpine3.20
container_name: catalystexplorer.redis
logging: *default-logging
ports:
- "${FORWARD_REDIS_PORT:-6379}:6379"
volumes:
- "catalystexplorer-redis:/data"
networks:
- catalystexplorer-net
healthcheck:
test:
- CMD
- redis-cli
- ping
retries: 3
timeout: 5s
# minio
catalystexplorer-minio:
image: "minio/minio:RELEASE.2025-02-18T16-25-55Z"
container_name: catalystexplorer-minio
ports:
- "${FORWARD_MINIO_PORT:-9001}:9001"
- "${FORWARD_MINIO_CONSOLE_PORT:-8900}:8900"
security_opt:
- no-new-privileges:true
environment:
MINIO_ROOT_USER: minio
MINIO_ROOT_PASSWORD: minioroot
MINIO_DEFAULT_BUCKET: catalystexplorer.com
volumes:
- "catalystexplorer-minio:/data/minio"
networks:
- catalystexplorer-net
- shared-network
command: 'minio server /data/minio --console-address ":${FORWARD_MINIO_CONSOLE_PORT:-8900}" --address ":${FORWARD_MINIO_PORT:-9001}"'
restart: always
logging: *default-logging
healthcheck:
test: ["CMD", "mc", "ready", "local"]
retries: 3
timeout: 5s
catalystexplorer.allure:
image: frankescobar/allure-docker-service:2.27.0
container_name: catalystexplorer.allure
ports:
- "5050:5050"
environment:
CHECK_RESULTS_EVERY_SECONDS: 5
KEEP_HISTORY: 1
KEEP_HISTORY_LATEST: 25
SECURITY_ENABLED: 0
MAKE_VIEWER_ENDPOINTS_PUBLIC: 1
volumes:
- "./application/allure-results:/app/allure-results"
- "./application/allure-reports:/app/default-reports"
networks:
- catalystexplorer-net
profiles:
- testing
# ollama AI service
catalystexplorer.ollama:
image: ollama/ollama:0.6.2
container_name: catalystexplorer.ollama
ports:
- "${FORWARD_OLLAMA_PORT:-11434}:11434"
volumes:
- "catalystexplorer-ollama:/root/.ollama"
- "./docker/scripts/ollama-init.sh:/ollama-init.sh"
networks:
- catalystexplorer-net
environment:
- OLLAMA_KEEP_ALIVE=24h
- OLLAMA_HOST=0.0.0.0
restart: unless-stopped
logging: *default-logging
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:11434/api/health"]
interval: 30s
timeout: 10s
retries: 3
start_period: 60s
createbuckets:
image: minio/mc
depends_on:
- catalystexplorer-minio
networks:
- catalystexplorer-net
- shared-network
entrypoint: >
/bin/sh -c "
until (/usr/bin/mc alias set minio http://catalystexplorer-minio:9001 minio minioroot) do echo '...waiting for minio...' && sleep 1; done;
/usr/bin/mc mb minio/catalystexplorer.com --ignore-existing;
/usr/bin/mc anonymous set public minio/catalystexplorer.com;
exit 0;
"
networks:
catalystexplorer-net:
driver: bridge
shared-network:
name: shared-network
driver: bridge
volumes:
catalystexplorer-minio:
driver: local
catalystexplorer-db:
driver: local
catalystexplorer-search:
driver: local
catalystexplorer-redis:
driver: local
catalystexplorer-ollama:
driver: local
test_catalystexplorer-db:
driver: local
node-ipc:
node-db:
db-data:
carp-db-data:
secrets:
pgpass:
file: ./config/carp/secrets/.pgpass