Skip to content

fix: resolve webhook caBundle deadlock during helm upgrade#163

Merged
lockwobr merged 1 commit intomainfrom
webhook
Feb 10, 2026
Merged

fix: resolve webhook caBundle deadlock during helm upgrade#163
lockwobr merged 1 commit intomainfrom
webhook

Conversation

@lockwobr
Copy link
Collaborator

During helm upgrade, the webhook configurations' caBundle field was reset to empty, causing new pods to fail readiness checks while the old leader pod never detected the change (only watched the cert Secret, with a 24h requeue). This created a deadlock where no pod could fix the caBundle.

  • Watch ValidatingWebhookConfiguration and MutatingWebhookConfiguration so the leader detects caBundle changes immediately
  • Use bytes.Equal for caBundle comparison instead of len==0 so stale values are corrected, not just empty ones
  • Remove caBundle from Helm webhook templates so upgrades stop resetting operator-managed values

During helm upgrade, the webhook configurations' caBundle field was
reset to empty, causing new pods to fail readiness checks while the
old leader pod never detected the change (only watched the cert
Secret, with a 24h requeue). This created a deadlock where no pod
could fix the caBundle.

- Watch ValidatingWebhookConfiguration and MutatingWebhookConfiguration
  so the leader detects caBundle changes immediately
- Use bytes.Equal for caBundle comparison instead of len==0 so stale
  values are corrected, not just empty ones
- Remove caBundle from Helm webhook templates so upgrades stop
  resetting operator-managed values
@lockwobr lockwobr self-assigned this Feb 10, 2026
@lockwobr lockwobr enabled auto-merge (rebase) February 10, 2026 00:53
@lockwobr lockwobr merged commit 97eea00 into main Feb 10, 2026
16 checks passed
@lockwobr lockwobr deleted the webhook branch February 10, 2026 01:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants