Gate consul readiness on raft leader, drop container caps
This commit is contained in:
@@ -42,6 +42,10 @@ spec:
|
||||
containers:
|
||||
- name: consul
|
||||
image: hashicorp/consul:1.22.7
|
||||
securityContext:
|
||||
allowPrivilegeEscalation: false
|
||||
capabilities:
|
||||
drop: [ALL]
|
||||
command:
|
||||
- /bin/sh
|
||||
- -ec
|
||||
@@ -65,8 +69,11 @@ spec:
|
||||
- {name: dns-tcp, containerPort: 8600, protocol: TCP}
|
||||
- {name: dns-udp, containerPort: 8600, protocol: UDP}
|
||||
readinessProbe:
|
||||
tcpSocket:
|
||||
port: 8301
|
||||
exec:
|
||||
command:
|
||||
- /bin/sh
|
||||
- -c
|
||||
- wget -qO- http://127.0.0.1:8500/v1/status/leader | grep -q ':8300'
|
||||
initialDelaySeconds: 5
|
||||
periodSeconds: 10
|
||||
resources:
|
||||
|
||||
Reference in New Issue
Block a user