-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsentinel.yml
49 lines (48 loc) · 959 Bytes
/
sentinel.yml
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
---
apiVersion: v1
kind: Service
metadata:
namespace: redis
labels:
name: redis-sentinel
role: service
name: redis-sentinel
spec:
ports:
- port: 26379
targetPort: 26379
selector:
app: redis-sentinel
---
apiVersion: apps/v1
kind: StatefulSet
metadata:
name: redis-sentinel
namespace: redis
spec:
serviceName: redis-sentinel
replicas: 3
selector:
matchLabels:
app: redis-sentinel
template:
metadata:
labels:
app: redis-sentinel
spec:
containers:
- name: redis-sentinel
image: kumojin/redis-sentinel:5.0.8
imagePullPolicy: Always
env:
- name: REDIS_MASTER
value: redis.redis
- name: REDIS_SENTINEL
value: redis-sentinel
readinessProbe:
tcpSocket:
port: 26379
initialDelaySeconds: 15
periodSeconds: 20
ports:
- containerPort: 26379