Repository navigation
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
71 lines (67 loc) · 1.62 KB
/
Copy pathdocker-compose.yml
File metadata and controls
71 lines (67 loc) · 1.62 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
# docker-compose.yml for multi-instance x402 deployment with Redis coordination
version: '3.8'
services:
redis:
image: redis:7-alpine
ports:
- "6379:6379"
command: redis-server --appendonly yes
volumes:
- redis-data:/data
healthcheck:
test: ["CMD", "redis-cli", "ping"]
interval: 5s
timeout: 3s
retries: 5
x402-1:
build:
context: .
dockerfile: Dockerfile.x402
environment:
X402_STORE: redis
REDIS_URL: redis://redis:6379/0
X402_LOCK_TTL_MS: "30000"
X402_LOCK_WAIT_MS: "1000"
X402_RESULT_TTL_MS: "600000"
LOG_LEVEL: info
PORT: "3000"
METRICS_PORT: "9090"
ports:
- "3000:3000"
- "9090:9090"
depends_on:
redis:
condition: service_healthy
healthcheck:
test: ["CMD", "wget", "--no-verbose", "--tries=1", "--spider", "http://localhost:3000/health"]
interval: 30s
timeout: 5s
retries: 3
restart: unless-stopped
x402-2:
build:
context: .
dockerfile: Dockerfile.x402
environment:
X402_STORE: redis
REDIS_URL: redis://redis:6379/0
X402_LOCK_TTL_MS: "30000"
X402_LOCK_WAIT_MS: "1000"
X402_RESULT_TTL_MS: "600000"
LOG_LEVEL: info
PORT: "3001"
METRICS_PORT: "9091"
ports:
- "3001:3000"
- "9091:9090"
depends_on:
redis:
condition: service_healthy
healthcheck:
test: ["CMD", "wget", "--no-verbose", "--tries=1", "--spider", "http://localhost:3000/health"]
interval: 30s
timeout: 5s
retries: 3
restart: unless-stopped
volumes:
redis-data: