Closed nishantapatil3 closed 1 year ago
CC: @pregnor @waynz0r @Laci21 @tiswanso (I couldnt assign reviewers)
@pregnor thanks for the review.
Added manual test cases in PR summary to verify pod readiness after deploy using kubectl get pod -n cluster-registry cluster-registry-controller-controller-xxx -o yaml
from status field
Thanks for the review guys, this is my first pull request so i am unable to merge.. please merge when possible, I'll create another PR to update charts and image versions
Thanks for the review and merge @Laci21 @pregnor @waynz0r
/readyz
as readiness probe)/metrics
as readiness probe)/metrics
as readiness probe)What's in this PR?
Add readiness probe to mark cluster-registry as "ready" only after webhook configuration certificate is updated successfully
Why?
cluster-registry generates self signed certificate to inject into webhook which take approx ~30 sec after deploy.
If we are running an automation script that waits for cluster-registrty to be ready then
/metrics
end point marks container as ready even before caBundle in injected into ValidatingWebhookConfig.As a result, the automation script would fail with
so we need to wait until the webhook is ready, then mark cluster-registry as "ready"
Additional context
This PR changes the readiness probe from
/metrics
to/readyz
which would potentially break API that depends on readiness probeChecklist
To Do
Tests
Webhook enabled (takes ~30 sec to be ready) (webhook ready health checker) Init "16:34:22" -> Ready "16:35:02" (40 seconds)
Webhook disabled (takes ~5 sec to be ready) (ping health checker) Init "16:29:06" -> Ready "16:29:10" (4 seconds)