Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[0.9] Honor Helm's MaxHistory when using drift correction #2517

Merged
merged 6 commits into from
Jun 14, 2024

Conversation

aruiz14
Copy link
Contributor

@aruiz14 aruiz14 commented Jun 14, 2024

Refers to #2515

  • Drift correction (self-healing) uses Helm's Rollback action, which has a MaxHistory field. This value takes precedence over the config value. Unlike the Upgrade action, we omitted to set this value, so the releases will only shrink when running an upgrade but not rollbacks`.
  • I noticed that sometimes, a regular upgrades would be deployed (creating a new). Initially I thought this would happen if all the releases in the remaining history were rollbacks, but realized the problem is that the BundleDeployment status has a release field, referencing the latest release installed. This value is not being updated on rollbacks, hence making the status differ from what helm history reflects.

@aruiz14 aruiz14 requested a review from a team as a code owner June 14, 2024 09:43
@aruiz14 aruiz14 changed the title Honor Helm's MaxHistory when using drift correction [0.9] Honor Helm's MaxHistory when using drift correction Jun 14, 2024
Copy link
Contributor

@weyfonk weyfonk left a comment

Choose a reason for hiding this comment

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

Thanks for troubleshooting and fixing this bug :)
Ideally we'd have tests for this, which in this case most likely mean end-to-end tests.

@aruiz14 aruiz14 force-pushed the max-history-rollbacks-0.9 branch from ec5c832 to f11e2fc Compare June 14, 2024 10:42
Co-authored-by: Corentin Néau <tan.neau@suse.com>
@weyfonk weyfonk merged commit d5421e2 into rancher:release/v0.9 Jun 14, 2024
10 checks passed
@aruiz14 aruiz14 deleted the max-history-rollbacks-0.9 branch June 14, 2024 11:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
JIRA Must shout
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

3 participants