Skip to content

fix(chart): agent-daemonset maxUnavailable:0 when surging (JEF-529)#269

Merged
thejefflarson merged 1 commit into
mainfrom
thejefflarson/jef-529-repo-chart-parity-agent-daemonset-maxunavailable0-when
Jul 26, 2026
Merged

fix(chart): agent-daemonset maxUnavailable:0 when surging (JEF-529)#269
thejefflarson merged 1 commit into
mainfrom
thejefflarson/jef-529-repo-chart-parity-agent-daemonset-maxunavailable0-when

Conversation

@thejefflarson

Copy link
Copy Markdown
Owner

Summary

charts/protector/templates/agent-daemonset.yaml's updateStrategy.rollingUpdate set maxSurge but never maxUnavailable, which defaults to 1. Kubernetes rejects a DaemonSet rollingUpdate with both non-zero ("maxSurge may not be set when maxUnavailable is non-zero"), so the chart was invalid-if-applied with the default agent.maxSurge: 1.

This adds the same conditional the cluster fork already carries, bringing the source chart to parity: surging (maxSurge > 0) sets maxUnavailable: 0; no surge falls back to the k8s default maxUnavailable: 1 (terminate-then-replace).

  • Closes JEF-529

Test plan

  • helm template charts/protector --set ingestAuth.token=dummy --set agent.enabled=truemaxSurge: 1, maxUnavailable: 0
  • helm template charts/protector --set ingestAuth.token=dummy --set agent.enabled=true --set agent.maxSurge=0maxSurge: 0, maxUnavailable: 1
  • helm lint charts/protector --set ingestAuth.token=dummy --set agent.enabled=true → clean (0 charts failed)
  • git diff --stat on this branch touches only agent-daemonset.yaml (+4 lines)

🤖 Generated with Claude Code

https://claude.ai/code/session_01VtjoJttCvBY4dzCoE4f9vP

DaemonSet rollingUpdate rejects both maxSurge and maxUnavailable being
non-zero simultaneously. With the default agent.maxSurge:1, this chart
never set maxUnavailable, so it defaulted to 1 — an invalid combination
that Kubernetes rejects at apply time. Brings the source chart to parity
with the cluster fork's identical fix: surge ⇒ maxUnavailable:0, no
surge ⇒ maxUnavailable:1 (default terminate-then-replace).

Closes JEF-529

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@thejefflarson
thejefflarson merged commit ffb1346 into main Jul 26, 2026
6 checks passed
@thejefflarson
thejefflarson deleted the thejefflarson/jef-529-repo-chart-parity-agent-daemonset-maxunavailable0-when branch July 26, 2026 22:53
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.

1 participant