-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcompose.yaml
More file actions
208 lines (196 loc) · 5.37 KB
/
compose.yaml
File metadata and controls
208 lines (196 loc) · 5.37 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
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
services:
redis_server_7000:
build:
dockerfile: redis-server.Dockerfile
ports:
- "7000:7000"
volumes:
- ./redis-server/test-cluster/7000/redis.conf:/etc/redis/redis.conf
command: /etc/redis/redis.conf
networks:
redis_network:
ipv4_address: 172.20.0.10
healthcheck:
test: ["CMD", "redis-cli", "-h", "172.20.0.10", "-p", "7000", "ping"]
interval: 10s
start_period: 3s
redis_server_7001:
build:
dockerfile: redis-server.Dockerfile
ports:
- "7001:7001"
volumes:
- ./redis-server/test-cluster/7001/redis.conf:/etc/redis/redis.conf
command: /etc/redis/redis.conf
networks:
redis_network:
ipv4_address: 172.20.0.11
healthcheck:
test: ["CMD", "redis-cli", "-h", "172.20.0.11", "-p", "7001", "ping"]
interval: 10s
start_period: 3s
redis_server_7002:
build:
dockerfile: redis-server.Dockerfile
ports:
- "7002:7002"
volumes:
- ./redis-server/test-cluster/7002/redis.conf:/etc/redis/redis.conf
command: /etc/redis/redis.conf
networks:
redis_network:
ipv4_address: 172.20.0.12
healthcheck:
test: ["CMD", "redis-cli", "-h", "172.20.0.12", "-p", "7002", "ping"]
interval: 10s
start_period: 3s
redis_server_7003:
build:
dockerfile: redis-server.Dockerfile
ports:
- "7003:7003"
volumes:
- ./redis-server/test-cluster/7003/redis.conf:/etc/redis/redis.conf
command: /etc/redis/redis.conf
networks:
redis_network:
ipv4_address: 172.20.0.13
healthcheck:
test: ["CMD", "redis-cli", "-h", "172.20.0.13", "-p", "7003", "ping"]
interval: 10s
start_period: 3s
redis_server_7004:
build:
dockerfile: redis-server.Dockerfile
ports:
- "7004:7004"
volumes:
- ./redis-server/test-cluster/7004/redis.conf:/etc/redis/redis.conf
command: /etc/redis/redis.conf
networks:
redis_network:
ipv4_address: 172.20.0.14
healthcheck:
test: ["CMD", "redis-cli", "-h", "172.20.0.14", "-p", "7004", "ping"]
interval: 10s
start_period: 3s
redis_server_7005:
build:
dockerfile: redis-server.Dockerfile
ports:
- "7005:7005"
volumes:
- ./redis-server/test-cluster/7005/redis.conf:/etc/redis/redis.conf
command: /etc/redis/redis.conf
networks:
redis_network:
ipv4_address: 172.20.0.15
healthcheck:
test: ["CMD", "redis-cli", "-h", "172.20.0.15", "-p", "7005", "ping"]
interval: 10s
start_period: 3s
redis_server_7006:
build:
dockerfile: redis-server.Dockerfile
ports:
- "7006:7006"
volumes:
- ./redis-server/test-cluster/7006/redis.conf:/etc/redis/redis.conf
command: /etc/redis/redis.conf
networks:
redis_network:
ipv4_address: 172.20.0.16
healthcheck:
test: ["CMD", "redis-cli", "-h", "172.20.0.16", "-p", "7006", "ping"]
interval: 10s
start_period: 3s
redis_server_7007:
build:
dockerfile: redis-server.Dockerfile
ports:
- "7007:7007"
volumes:
- ./redis-server/test-cluster/7007/redis.conf:/etc/redis/redis.conf
command: /etc/redis/redis.conf
networks:
redis_network:
ipv4_address: 172.20.0.17
healthcheck:
test: ["CMD", "redis-cli", "-h", "172.20.0.17", "-p", "7007", "ping"]
interval: 10s
start_period: 3s
redis_server_7008:
build:
dockerfile: redis-server.Dockerfile
ports:
- "7008:7008"
volumes:
- ./redis-server/test-cluster/7008/redis.conf:/etc/redis/redis.conf
command: /etc/redis/redis.conf
networks:
redis_network:
ipv4_address: 172.20.0.18
healthcheck:
test: ["CMD", "redis-cli", "-h", "172.20.0.18", "-p", "7008", "ping"]
interval: 10s
start_period: 3s
cluster_configurator:
build:
dockerfile_inline: |
FROM debian:bullseye-slim
RUN apt-get update && apt-get install -y redis-tools && rm -rf /var/lib/apt/lists/*
command:
bash /config-cluster.conf
volumes:
- ./config-cluster.sh:/config-cluster.conf
depends_on:
redis_server_7000:
condition: service_healthy
redis_server_7001:
condition: service_healthy
redis_server_7002:
condition: service_healthy
redis_server_7003:
condition: service_healthy
redis_server_7004:
condition: service_healthy
redis_server_7005:
condition: service_healthy
redis_server_7006:
condition: service_healthy
redis_server_7007:
condition: service_healthy
redis_server_7008:
condition: service_healthy
networks:
- redis_network
docs_syncer:
build:
dockerfile: docs-syncer.Dockerfile
environment:
REDIS_HOST: 172.20.0.16
REDIS_PORT: 7006
depends_on:
cluster_configurator:
condition: service_completed_successfully
restart: true
networks:
- redis_network
docs_gpt:
build:
dockerfile: docs-gpt.Dockerfile
environment:
OPENAI_API_KEY: ${OPENAI_API_KEY:?}
REDIS_HOST: 172.20.0.16
REDIS_PORT: 7006
depends_on:
cluster_configurator:
condition: service_completed_successfully
restart: true
networks:
- redis_network
networks:
redis_network:
ipam:
config:
- subnet: 172.20.0.0/24