-
Notifications
You must be signed in to change notification settings - Fork 141
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
add reset_then_reuse_values support to helm module #802
base: main
Are you sure you want to change the base?
add reset_then_reuse_values support to helm module #802
Conversation
Build succeeded. ✔️ ansible-galaxy-importer SUCCESS in 4m 32s |
630d747
to
01b422e
Compare
01b422e
to
6486e64
Compare
Build succeeded. ✔️ ansible-galaxy-importer SUCCESS in 5m 13s |
Build succeeded. ✔️ ansible-galaxy-importer SUCCESS in 4m 51s |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@b0z02003 Thanks for submitting this PR.
In addition to the requested changes, you must include the new test files in main.yml
of the corresponding integration test targets.
Co-authored-by: Bikouo Aubin <[email protected]>
Build succeeded. ✔️ ansible-galaxy-importer SUCCESS in 4m 48s |
@abikouo Thanks for the suggestions ! I've tried to improve on them to also check for helm version and added the integration tests (that was a big oversight on my part, my bad). |
Build succeeded. ✔️ ansible-galaxy-importer SUCCESS in 4m 14s |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This will address linters issues
if reset_then_reuse_values: | ||
helm_version = module.get_helm_version() | ||
if LooseVersion(helm_version) < LooseVersion("3.14.0"): | ||
module.warn("helm support option --reset-then-reuse-values starting release >= 3.14.0") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
module.warn("helm support option --reset-then-reuse-values starting release >= 3.14.0") | |
module.warn( | |
"helm support option --reset-then-reuse-values starting release >= 3.14.0" | |
) |
if LooseVersion(helm_diff_version) < LooseVersion("3.9.12"): | ||
module.warn("helm diff support option --reset-then-reuse-values starting release >= 3.9.12") | ||
elif LooseVersion(helm_version) < LooseVersion("3.14.0"): | ||
module.warn("helm support option --reset-then-reuse-values starting release >= 3.14.0") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
module.warn("helm support option --reset-then-reuse-values starting release >= 3.14.0") | |
module.warn( | |
"helm support option --reset-then-reuse-values starting release >= 3.14.0" | |
) |
helm_diff_version = get_plugin_version("diff") | ||
helm_version = module.get_helm_version() | ||
if LooseVersion(helm_diff_version) < LooseVersion("3.9.12"): | ||
module.warn("helm diff support option --reset-then-reuse-values starting release >= 3.9.12") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
module.warn("helm diff support option --reset-then-reuse-values starting release >= 3.9.12") | |
module.warn( | |
"helm diff support option --reset-then-reuse-values starting release >= 3.9.12" | |
) |
SUMMARY
Starting with version 3.14.0, Helm supports
--reset-then-reuse-values
. As discussed on the original PR. This greatly improves on--reuse-values
as it allows to avoid templates errors when new features are added to an upgraded chart.Closes #803
ISSUE TYPE
COMPONENT NAME
helm
ADDITIONAL INFORMATION
This PR is greatly 'inspired' by #575 and because I wasn't sure how I could provide additional tests for it, I actually copied those build previously for
--reuse-values
(as it is an improvement on this feature.