-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
96 lines (88 loc) · 2.43 KB
/
Copy pathdocker-compose.yml
File metadata and controls
96 lines (88 loc) · 2.43 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
name: tool-bridge
x-app-image: &app-image
image: ghcr.io/tokenrollai/tool-bridge:0.24.0
services:
init:
<<: *app-image
user: '0:0'
restart: 'no'
command: [node, /app/dist/admin.js, init]
volumes:
- bootstrap:/data
- pg-secrets:/secrets/postgres
- s3-secrets:/secrets/s3
postgres:
image: postgres:18.4-bookworm
restart: unless-stopped
depends_on:
init:
condition: service_completed_successfully
environment:
POSTGRES_USER: postgres
POSTGRES_DB: toolbridge
POSTGRES_PASSWORD_FILE: /run/tb-postgres/password
volumes:
- postgres-data:/var/lib/postgresql
- pg-secrets:/run/tb-postgres:ro
- pg-secrets:/docker-entrypoint-initdb.d:ro
healthcheck:
test: [CMD-SHELL, 'pg_isready -U postgres -d toolbridge']
interval: 5s
timeout: 3s
retries: 12
objects:
image: chrislusf/seaweedfs:4.45@sha256:fc9f76fa993ad69966ffeb2f65d0318fcae39c6f8e20cf68ef7b3a5cb97769e5
restart: unless-stopped
depends_on:
init:
condition: service_completed_successfully
command: [server, -ip=objects, -ip.bind=0.0.0.0, -master.peers=objects:9333, -master.telemetry=false, -s3, -s3.config=/run/tb-s3/s3.json, -dir=/data, -volume.max=32, -master.volumeSizeLimitMB=1024]
volumes:
- objects-data:/data
- s3-secrets:/run/tb-s3:ro
init-bucket:
<<: *app-image
user: '0:0'
restart: 'no'
depends_on:
objects:
condition: service_started
command: [node, /app/dist/admin.js, init-bucket]
volumes:
- s3-secrets:/secrets/s3:ro
app:
<<: *app-image
init: true
restart: unless-stopped
depends_on:
init:
condition: service_completed_successfully
postgres:
condition: service_healthy
init-bucket:
condition: service_completed_successfully
ports:
- '127.0.0.1:8787:8787'
volumes:
- bootstrap:/data
healthcheck:
test: [CMD, node, -e, "fetch('http://127.0.0.1:8787/healthz').then(r=>process.exit(r.ok?0:1),()=>process.exit(1))"]
interval: 5s
timeout: 3s
retries: 12
redis:
image: redis:8.10.1-alpine
profiles: [replicas]
restart: unless-stopped
command: [redis-server, --appendonly, 'no']
healthcheck:
test: [CMD, redis-cli, ping]
interval: 5s
timeout: 3s
retries: 12
volumes:
bootstrap:
postgres-data:
objects-data:
pg-secrets:
s3-secrets: