-
Notifications
You must be signed in to change notification settings - Fork 40
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 ability to stop updating agent components temporarily #80
Comments
We were able to implement this in our addon controller by overriding the But now I'm worried that the empty slice is relying on the current implementation... specifically: https://github.com/open-cluster-management-io/addon-framework/blob/main/pkg/addonmanager/controllers/agentdeploy/controller.go. So right now, an empty slice results in the ManfestWork getting ignored, but it would also make sense if an empty slice resulted in deleting the existing ManifestWork. |
Having a consistent way of doing this for all addons is appealing so we can define a consistent interface before 2.5 is released and support gets trained to use different pause annotations per addon. |
hrm, that is interesting. agree we should have a consistent way. |
/kind feature |
It seems that this workaround no longer works due to this change: |
I'm thinking about a change to https://github.com/open-cluster-management-io/addon-framework/blob/main/pkg/addonmanager/controllers/agentdeploy/controller.go#L147-L167 So that a Opinions? |
FYI @zhiweiyin318 |
The "pause" hack no longer works with the latest addon-framework library. The alternative, which is in this commit, is to return an error in the `Manifests` method when the pause annotation is set. It does spam the logs but since this isn't a setting that should be used in production, this seems okay until the following is addressed: open-cluster-management-io/addon-framework#80 Relates: stolostron/backlog#24362 Signed-off-by: mprahl <[email protected]>
The "pause" hack no longer works with the latest addon-framework library. The alternative, which is in this commit, is to return an error in the `Manifests` method when the pause annotation is set. It does spam the logs but since this isn't a setting that should be used in production, this seems okay until the following is addressed: open-cluster-management-io/addon-framework#80 Relates: stolostron/backlog#24362 Signed-off-by: mprahl <[email protected]> (cherry picked from commit 12cfe6e3f51534f0d10edab037bbaf49d7f298e2)
Currently, any modifications to the ManifestWork will be reverted by the addon controller. So, the only modifications that can be made to addon agents on managed clusters are the ones specifically allowed by the addon.
In development or troubleshooting scenarios, it might be helpful to deploy a change to one addon on a cluster without updating the addon controller. For example, to add another argument to an addon agent container in order to enable a feature flag.
In stolostron, several controllers have "pause" annotations that can be placed on their resources, which prevent the controller from reconciling them. Something similar here could be useful.
The text was updated successfully, but these errors were encountered: