-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yaml
More file actions
131 lines (123 loc) · 2.93 KB
/
Copy pathdocker-compose.yaml
File metadata and controls
131 lines (123 loc) · 2.93 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
services:
runway:
build:
context: .
args:
VERSION: ${VERSION:-dev}
BUILD_TIME: ${BUILD_TIME:-}
image: ghcr.io/wudi/runway:${VERSION:-dev}
ports:
- "8080:8080"
- "8081:8081"
- "8082:8082"
environment:
- JWT_SECRET=your-secret-key-here
volumes:
- ./configs:/app/configs:ro
- certs:/app/certs:ro
- specs:/app/specs:ro
- geoip:/app/geoip:ro
depends_on:
backend1:
condition: service_healthy
backend2:
condition: service_healthy
networks:
- runway-network
# Mock backend services for testing
backend1:
image: nginx:alpine
volumes:
- ./test/nginx/backend1.conf:/etc/nginx/conf.d/default.conf:ro
networks:
- runway-network
healthcheck:
test: ["CMD-SHELL", "wget --no-verbose --tries=1 --spider http://localhost/ || exit 1"]
interval: 10s
timeout: 5s
retries: 3
backend2:
image: nginx:alpine
volumes:
- ./test/nginx/backend2.conf:/etc/nginx/conf.d/default.conf:ro
networks:
- runway-network
healthcheck:
test: ["CMD-SHELL", "wget --no-verbose --tries=1 --spider http://localhost/ || exit 1"]
interval: 10s
timeout: 5s
retries: 3
# Redis for distributed rate limiting and caching
redis:
image: redis:7-alpine
ports:
- "6379:6379"
volumes:
- redis-data:/data
networks:
- runway-network
healthcheck:
test: ["CMD", "redis-cli", "ping"]
interval: 10s
timeout: 5s
retries: 3
profiles:
- redis
# Consul for service discovery
consul:
image: hashicorp/consul:1.17
ports:
- "8500:8500"
command: agent -dev -client=0.0.0.0
networks:
- runway-network
healthcheck:
test: ["CMD", "consul", "members"]
interval: 10s
timeout: 5s
retries: 3
profiles:
- consul
# etcd for service discovery
etcd:
image: quay.io/coreos/etcd:v3.5.17
ports:
- "2379:2379"
environment:
ETCD_ADVERTISE_CLIENT_URLS: http://etcd:2379
ETCD_LISTEN_CLIENT_URLS: http://0.0.0.0:2379
networks:
- runway-network
healthcheck:
test: ["CMD", "etcdctl", "endpoint", "health"]
interval: 10s
timeout: 5s
retries: 3
profiles:
- etcd
# OpenTelemetry Collector for tracing
otel-collector:
image: otel/opentelemetry-collector-contrib:0.115.0
ports:
- "4317:4317" # OTLP gRPC
- "4318:4318" # OTLP HTTP
- "13133:13133" # Health check
volumes:
- ./configs/otel-collector.yaml:/etc/otelcol-contrib/config.yaml:ro
networks:
- runway-network
healthcheck:
test: ["CMD-SHELL", "wget --no-verbose --tries=1 --spider http://localhost:13133/ || exit 1"]
interval: 10s
timeout: 5s
retries: 3
profiles:
- otel
volumes:
certs:
specs:
geoip:
redis-data:
networks:
runway-network:
driver: bridge