-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
158 lines (153 loc) · 4.78 KB
/
Copy pathdocker-compose.yml
File metadata and controls
158 lines (153 loc) · 4.78 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
services:
postgres:
image: postgres:16-alpine
container_name: bjj-projections
environment:
- POSTGRES_DB=chainsync
- POSTGRES_USER=postgres
- POSTGRES_PASSWORD=postgres
volumes:
- pgdata:/var/lib/postgresql/data
ports:
- "5432:5432"
healthcheck:
test: ["CMD-SHELL", "pg_isready -U postgres -d chainsync || exit 1"]
interval: 30s
timeout: 5s
retries: 10
start_period: 10s
restart: unless-stopped
chainsync:
image: mariusgeorgescu/bjj-chainsync:e36ddc2
container_name: bjj-chainsync
environment:
- KUPO_URL=${KUPO_URL}
- PG_CONN_STR=host=postgres user=postgres password=postgres dbname=chainsync port=5432
- BATCH_SIZE=1000000
- FETCH_BATCH_SIZE=100000
- ATLAS_CORE_CONFIG=${ATLAS_CORE_CONFIG}
- DEPLOYED_VALIDATORS_CONFIG=${DEPLOYED_VALIDATORS_CONFIG}
depends_on:
postgres:
condition: service_healthy
ports:
- "8084:8084"
healthcheck:
test: ["CMD-SHELL", "curl -fsS http://localhost:8084/ready || exit 1"] # It makes more sense to use readiness check here (the chaintip shoud be uptodate or close behind)
interval: 10s
timeout: 5s
retries: 12000
start_period: 10s
restart: unless-stopped
ipfs:
image: ipfs/kubo:latest
container_name: bjj-ipfs
entrypoint: /bin/sh
command:
- -c
- |
ipfs init --profile=server 2>/dev/null
ipfs config --json Gateway.NoFetch true
ipfs daemon --enable-gc
volumes:
- ipfs-data:/data/ipfs
ports:
- "4001:4001" # Swarm (P2P) TCP
- "4001:4001/udp" # Swarm (P2P) QUIC
- "5001:5001" # API
- "8080:8080" # API -- local dev only, not exposed in production
# 8080 removed -- gateway internal only, accessed via BFF proxy
# 8081 removed -- writable gateway not needed externally
healthcheck:
test: ["CMD-SHELL", "ipfs dag stat /ipfs/QmUNLLsPACCz1vLxQVkXqqLX5R1X345qqfHbsf67hvA3Nn || exit 1"]
interval: 30s
timeout: 5s
retries: 10
start_period: 15s
restart: unless-stopped
interaction-api:
image: mariusgeorgescu/bjj-interaction-api:e36ddc2
container_name: bjj-interaction-api
environment:
- PORT=8082
- BASIC_USER=${BASIC_USER}
- BASIC_PASS=${BASIC_PASS}
- CORS_ALLOWED_ORIGINS=${CORS_ALLOWED_ORIGINS}
- ATLAS_CORE_CONFIG=${ATLAS_CORE_CONFIG}
- DEPLOYED_VALIDATORS_CONFIG=${DEPLOYED_VALIDATORS_CONFIG}
- IPFS_API_URL=http://ipfs:5001
ports:
- "8082:8082"
depends_on:
chainsync:
condition: service_healthy
postgres:
condition: service_healthy
ipfs:
condition: service_healthy
restart: unless-stopped
command: ["/app/interaction-api"]
healthcheck:
test: ["CMD-SHELL", "curl -fsS http://localhost:8082/health || exit 1"]
interval: 30s
timeout: 5s
retries: 10
start_period: 10s
query-api:
image: mariusgeorgescu/bjj-query-api:e36ddc2
container_name: bjj-query-api
environment:
- PORT=8083
- PG_CONN_STR=host=postgres user=postgres password=postgres dbname=chainsync port=5432
- BASIC_USER=${BASIC_USER}
- BASIC_PASS=${BASIC_PASS}
- CORS_ALLOWED_ORIGINS=${CORS_ALLOWED_ORIGINS}
- ATLAS_CORE_CONFIG=${ATLAS_CORE_CONFIG}
- DEPLOYED_VALIDATORS_CONFIG=${DEPLOYED_VALIDATORS_CONFIG}
ports:
- "8083:8083"
depends_on:
chainsync:
condition: service_healthy
postgres:
condition: service_healthy
restart: unless-stopped
command: ["/app/query-api"]
healthcheck:
test: ["CMD-SHELL", "curl -fsS http://localhost:8083/health || exit 1"]
interval: 30s
timeout: 5s
retries: 10
start_period: 10s
mcp-server:
image: mariusgeorgescu/bjj-mcp-server:e36ddc2
container_name: bjj-mcp-server
environment:
- PORT=8085
- QUERY_API_URL=http://query-api:8083
- INTERACTION_API_URL=http://interaction-api:8082
- BASIC_USER=${BASIC_USER}
- BASIC_PASS=${BASIC_PASS}
- CORS_ALLOWED_ORIGINS=${CORS_ALLOWED_ORIGINS}
- MCP_ENABLE_WRITE_TX=1
ports:
- "8085:8085"
depends_on:
query-api:
condition: service_healthy
interaction-api:
condition: service_healthy
restart: unless-stopped
command: ["/app/mcp-server"]
healthcheck:
test: ["CMD-SHELL", "curl -fsS http://localhost:8085/health || exit 1"]
interval: 30s
timeout: 5s
retries: 10
start_period: 10s
# This is a dev/audit stack — protocol services only. The product deployment
# (FE + BFF + agent-service + Redis + TLS ingress) lives in the private
# `bjj-frontend` repo, which pulls these images from Docker Hub via PROTOCOL_TAG.
volumes:
pgdata:
ipfs-data: