Skip to content

Commit 8c2fdb6

Browse files
committed
fix(e2e): improve dind-sidecar probe configuration for reliability
Add startupProbe with failureThreshold of 30 to allow more time for Docker daemon initialization. Change readinessProbe to use 'docker info' command which verifies the daemon is actually ready to accept commands. This is a cherry-pick of the probe changes from tektoncd#9242 on main.
1 parent f93dd2f commit 8c2fdb6

File tree

1 file changed

+10
-2
lines changed

1 file changed

+10
-2
lines changed

examples/v1/taskruns/dind-sidecar.yaml

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,11 +59,19 @@ spec:
5959
- mountPath: /certs/client
6060
name: dind-certs
6161
# Wait for the dind daemon to generate the certs it will share with the
62-
# client.
63-
readinessProbe:
62+
# client. StartupProbe handles slow Docker daemon initialization.
63+
startupProbe:
6464
periodSeconds: 1
65+
failureThreshold: 30 # Allow up to 30 seconds for Docker daemon to start
6566
exec:
6667
command: ['ls', '/certs/client/ca.pem']
68+
# ReadinessProbe verifies Docker daemon is actually ready to accept commands.
69+
# Note: With k8s native sidecar support, startupProbe is honored but
70+
# readinessProbe may not be.
71+
readinessProbe:
72+
periodSeconds: 2
73+
exec:
74+
command: ['docker', 'info']
6775

6876
volumes:
6977
- name: dind-certs

0 commit comments

Comments
 (0)