Skip to content

fix(argo-rollouts): hash only config data in checksum/cm annotation - #4079

Merged
tico24 merged 2 commits into
argoproj:mainfrom
DrFaust92:fix/rollouts-checksum-chart-churn
Sep 17, 2026
Merged

tico24 merged 2 commits into
argoproj:mainfrom
DrFaust92:fix/rollouts-checksum-chart-churn

Conversation

@DrFaust92

Copy link
Copy Markdown
Contributor

Ports the argo-cd fix from #4044 to argo-rollouts.

checksum/cm hashed the entire rendered ConfigMap, whose metadata.labels include helm.sh/chart. That value changes on every chart version bump, so the controller was rolled on every upgrade even when no configuration had changed. The argo-rollouts.config.checksum helper hashes only the data/stringData sections instead.

Rendered 2.43.1 against a bumped version with the same values: the checksum is unchanged after this PR and differs before it. Changing controller.trafficRouterPlugins still changes it. Upgrading to this version rolls the controller once as the annotation value changes.

argo-workflows, argo-events and argocd-image-updater have the same pattern — happy to follow up with separate PRs.

Checklist:

  • I have bumped the chart version according to versioning
  • I have updated the documentation according to documentation
  • I have updated the chart changelog with all the changes that come with this pull request according to changelog.
  • Any new values are backwards compatible and/or have sensible default.
  • I have signed off all my commits as required by DCO.
  • I have created a separate pull request for each chart according to pull requests
  • My build is green (troubleshooting builds).

The annotation hashed the entire rendered ConfigMap, whose metadata.labels
include the helm.sh/chart value. That value changes on every chart version
bump, so the controller was rolled on every upgrade even when no configuration
actually changed.

Use the same data-only hashing as argo-cd (argoproj#4044): a pure version bump no
longer changes the checksum, while a real data change still rolls the pod.

Signed-off-by: Ilia Lazebnik <ilia.lazebnik@gmail.com>

@jmeridth jmeridth left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤖 (summary) Verified port of the #4044 data-only checksum pattern, and verified empirically: with this PR applied, a chart version bump leaves checksum/cm unchanged while a real config change (e.g. adding a trafficRouterPlugins entry) moves it, and createConfigmap=false renders safely. Helper matches the argo-cd original, the controller deployment is the chart's only checksum site, and 2.43.2 is the right patch. One changelog item to align with the #4044 precedent (inline), then this is an approve. Thanks @DrFaust92 for spreading the fix.

Comment thread charts/argo-rollouts/Chart.yaml Resolved
Review: ship as kind: changed with the one-time roll disclosed, matching argoproj#4044.
Signed-off-by: Ilia Lazebnik <ilia.lazebnik@gmail.com>
@DrFaust92
DrFaust92 requested a review from jmeridth September 14, 2026 02:41

@jmeridth jmeridth left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤖 (summary) Suggestion applied verbatim: changelog now carries kind: changed with the one-time-roll disclosure, matching the #4044 precedent. Code was already verified empirically in the prior review (hash stable across a version bump, moves on config change, empty-CM safe). CI green. LGTM, thanks @DrFaust92.

@tico24
tico24 merged commit 45e4543 into argoproj:main Sep 17, 2026
7 checks passed
@DrFaust92
DrFaust92 deleted the fix/rollouts-checksum-chart-churn branch October 8, 2026 12:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants