-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcompose.dev.yaml
More file actions
65 lines (62 loc) · 1.35 KB
/
Copy pathcompose.dev.yaml
File metadata and controls
65 lines (62 loc) · 1.35 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
services:
redis:
image: redis:8-alpine
ports:
- 6379:6379
healthcheck:
test: ["CMD", "redis-cli", "ping"]
interval: 5s
timeout: 3s
retries: 5
start_period: 5s
volumes:
- redis-data:/data
socket-proxy:
image: tecnativa/docker-socket-proxy
restart: unless-stopped
environment:
- PING=1
- VERSION=1
- BUILD=1
- IMAGES=1
- CONTAINERS=1
- NETWORKS=1
- POST=1
- DELETE=1
volumes:
- /var/run/docker.sock:/var/run/docker.sock:ro
healthcheck:
test: ["CMD", "wget", "-q", "--spider", "http://localhost:2375/_ping"]
interval: 2s
timeout: 2s
retries: 10
start_period: 2s
relay:
build: .
container_name: relay
depends_on:
redis:
condition: service_healthy
socket-proxy:
condition: service_healthy
ports:
- 9090:9090
environment:
- REDIS_URI=redis:6379
- REDIS_STREAM=events
- REDIS_GROUP=relay
- METRICS_ADDR=:9090
- LOG_LEVEL=DEBUG
- DOCKER_HOST=tcp://socket-proxy:2375
healthcheck:
test: ["CMD", "relay", "health"]
interval: 10s
timeout: 3s
retries: 3
start_period: 10s
volumes:
- ./examples/functions:/functions:ro
- relay-data:/var/lib/relay
volumes:
redis-data:
relay-data: