Skip to content

🐛 Improve deployment with Argocd by allowing to remove helm hooks #751

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

Merged
merged 1 commit into from
Mar 21, 2025

Conversation

afarbos
Copy link
Contributor

@afarbos afarbos commented Mar 14, 2025

What this PR does / why we need it:

Allow to disable have helm hooks. This help with argocd resource management (cannot autosync, no proper tracking of resources on deletion) and avoid deleting all hook resources each time we need to sync. This can be scary if the un-install does not work as expected and stuck the app state with no provider running.

Argocd automatically convert hooks from helm and there is no way to avoid that once those are set the resource will be considered deployed by a hook.
For reference here is the conversion: https://argo-cd.readthedocs.io/en/stable/user-guide/helm/#helm-hooks
By enabling the removal of helm hooks, argocd will still install the resource in the right order using the phase only ( https://argo-cd.readthedocs.io/en/stable/user-guide/sync-waves/#how-do-i-configure-waves )

Which issue(s) this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close the issue(s) when PR gets merged):
Fixes #562

@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Mar 14, 2025
@k8s-ci-robot k8s-ci-robot added the needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. label Mar 14, 2025
@k8s-ci-robot
Copy link
Contributor

Hi @afarbos. Thanks for your PR.

I'm waiting for a kubernetes-sigs member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@afarbos afarbos changed the title fix: allow removing helm hooks fix: allow removing helm hooks / Improve argocd management Mar 14, 2025
@k8s-ci-robot k8s-ci-robot added the size/M Denotes a PR that changes 30-99 lines, ignoring generated files. label Mar 14, 2025
Copy link

netlify bot commented Mar 14, 2025

Deploy Preview for kubernetes-sigs-cluster-api-operator ready!

Name Link
🔨 Latest commit 5ea7523
🔍 Latest deploy log https://app.netlify.com/sites/kubernetes-sigs-cluster-api-operator/deploys/67dc614ae3ac9a00088782d7
😎 Deploy Preview https://deploy-preview-751--kubernetes-sigs-cluster-api-operator.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@afarbos afarbos changed the title fix: allow removing helm hooks / Improve argocd management fix: Allow removing helm hooks and Improve deployment with argocd Mar 14, 2025
@afarbos afarbos changed the title fix: Allow removing helm hooks and Improve deployment with argocd 🐛 Improve deployment with Argocd by allowing to remove helm hooks Mar 14, 2025
@furkatgofurov7
Copy link
Member

/ok-to-test

cc @dtzar would it be possible to test this patch before we take it in?

@k8s-ci-robot k8s-ci-robot added ok-to-test Indicates a non-member PR verified by an org member that is safe to test. and removed needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Mar 17, 2025
@afarbos afarbos force-pushed the af/argocdsynchook branch from 78c20ac to 79c05e7 Compare March 19, 2025 20:46
@k8s-ci-robot k8s-ci-robot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. and removed size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Mar 19, 2025
@afarbos
Copy link
Contributor Author

afarbos commented Mar 19, 2025

til make test-e2e-local, make it way simpler to debug those!
🤞 test should pass

Copy link
Contributor

@alexander-demicev alexander-demicev left a comment

Choose a reason for hiding this comment

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

/approve

please, squash commits

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: alexander-demicev

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Mar 20, 2025
@furkatgofurov7
Copy link
Member

LGTM pending squash

@afarbos afarbos force-pushed the af/argocdsynchook branch from 2e05fb1 to 5ea7523 Compare March 20, 2025 18:41
@afarbos
Copy link
Contributor Author

afarbos commented Mar 20, 2025

Copy link
Member

@furkatgofurov7 furkatgofurov7 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 the PR @afarbos!

/lgtm

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Mar 21, 2025
@k8s-ci-robot
Copy link
Contributor

LGTM label has been added.

Git tree hash: ef75e9cc63b2d2d8c20d390c1b09f85eda1bfe03

@k8s-ci-robot k8s-ci-robot merged commit 46d9112 into kubernetes-sigs:main Mar 21, 2025
14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. ok-to-test Indicates a non-member PR verified by an org member that is safe to test. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Automatic deletion of all providers
4 participants