Fix pod probes yaml file
This commit is contained in:
@@ -65,7 +65,7 @@ kubectl create -f https://k8s.io/docs/tasks/configure-pod-container/exec-livenes
|
|||||||
|
|
||||||
Within 30 seconds, view the Pod events:
|
Within 30 seconds, view the Pod events:
|
||||||
|
|
||||||
```
|
```shell
|
||||||
kubectl describe pod liveness-exec
|
kubectl describe pod liveness-exec
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|||||||
@@ -1,22 +1,17 @@
|
|||||||
apiVersion: v1
|
apiVersion: v1
|
||||||
kind: Pod
|
kind: Pod
|
||||||
|
|
||||||
metadata:
|
metadata:
|
||||||
labels:
|
labels:
|
||||||
test: liveness
|
test: liveness
|
||||||
name: liveness-exec
|
name: liveness-exec
|
||||||
spec:
|
spec:
|
||||||
containers:
|
containers:
|
||||||
|
|
||||||
- name: liveness
|
- name: liveness
|
||||||
|
image: gcr.io/google_containers/busybox
|
||||||
args:
|
args:
|
||||||
- /bin/sh
|
- /bin/sh
|
||||||
- -c
|
- -c
|
||||||
- touch /tmp/healthy; sleep 30; rm -rf /tmp/healthy; sleep 600
|
- touch /tmp/healthy; sleep 30; rm -rf /tmp/healthy; sleep 600
|
||||||
|
|
||||||
image: gcr.io/google_containers/busybox
|
|
||||||
|
|
||||||
livenessProbe:
|
livenessProbe:
|
||||||
exec:
|
exec:
|
||||||
command:
|
command:
|
||||||
|
|||||||
@@ -6,14 +6,10 @@ metadata:
|
|||||||
name: liveness-http
|
name: liveness-http
|
||||||
spec:
|
spec:
|
||||||
containers:
|
containers:
|
||||||
|
|
||||||
- name: liveness
|
- name: liveness
|
||||||
|
image: gcr.io/google_containers/liveness
|
||||||
args:
|
args:
|
||||||
- /server
|
- /server
|
||||||
|
|
||||||
image: gcr.io/google_containers/liveness
|
|
||||||
|
|
||||||
livenessProbe:
|
livenessProbe:
|
||||||
httpGet:
|
httpGet:
|
||||||
path: /healthz
|
path: /healthz
|
||||||
|
|||||||
Reference in New Issue
Block a user