Pass --revision to helm diff upgrade - #1046
Open
sepich wants to merge 1 commit into
Open
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Adds explicit revision selection to helm diff upgrade, enabling comparison against a known deployed revision after a failed upgrade.
Changes:
- Adds and validates the
--revisionflag. - Applies the revision to manifest and hook retrieval.
- Refactors Helm get arguments and adds unit tests/documentation.
Reviewed changes
Copilot reviewed 8 out of 8 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| README.md | Documents the new flag. |
| cmd/upgrade.go | Adds revision handling and validation. |
| cmd/upgrade_test.go | Tests revision validation. |
| cmd/helm.go | Centralizes revision-aware Helm get arguments. |
| cmd/helm_test.go | Tests generated Helm arguments. |
| cmd/rollback.go | Adopts the revised helper signature. |
| cmd/revision.go | Reuses the unified release helper. |
| cmd/release.go | Adopts the revised helper signature. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
| // A revision of 0 means no --revision flag is passed, so helm defaults to the | ||
| // newest revision of the release regardless of its status. | ||
| func helmGetArgs(what, release string, revision int, namespace, kubeContext string) []string { | ||
| args := []string{"get", what, release} |
Collaborator
|
@sepich any changes required in helmfile/helmfile? |
Collaborator
|
@sepich please fix ci issue. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
fix for #1045
via passing specific
--revisiontohelm diff upgradeMight be better to change that to to use the newest revision with
status: deployedas the baseline rather than the newest revision (gated by new cli arg?)