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

Improve CNAO/KMP CONTROL_PLANE_KEY flow #1567

Open
oshoval opened this issue Jun 15, 2023 · 6 comments
Open

Improve CNAO/KMP CONTROL_PLANE_KEY flow #1567

oshoval opened this issue Jun 15, 2023 · 6 comments
Labels
lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed.

Comments

@oshoval
Copy link
Collaborator

oshoval commented Jun 15, 2023

What happened:
CNAO has to remove the KUBEMACPOOL_CONTROL_PLANE_KEY because of two cases:

  1. It is in KMP manifest under the NS, so before applying the NS it need to remove it.
    (even that it already exists, it will amend it IIRC),
    See https://github.com/kubevirt/cluster-network-addons-operator/pull/1145/files#r796372158
    PR manifests: Remove control-plane label from namespace k8snetworkplumbingwg/kubemacpool#389 removes it,
    once there will be a KMP release we can remove the deletion during reconcile.

  2. For backward compatibility, for versions that had this label before the fix presented by labels: Do not label operator namespace with unneeded labels #1145
    We remove the labels by cleanUpNamespaceLabels.

What you expected to happen:
Code should be cleaner and easier, while maintaining the functionality.

About 1:
We can remove it from KMP itself, and then we can remove the code mentioned on 1, see link above.
Note that we might can already remove it now due to #1566 which removes it in the KMP bump.

About 2:
Once we don't support anymore a version that had the bug pre 1145 we can remove this function.

How to reproduce it (as minimally and precisely as possible):
See notes above.

Anything else we need to know?:
Maybe we can even consider removing the NS resources in all CNAO component bump scripts.
Can be done either in the component bump scripts or maybe the reconcile should just ignore it ?

I think once we fix it, it is better to remove this code as well
https://github.com/kubevirt/cluster-network-addons-operator/pull/1566/files#diff-bec741ac25fac96fd708633e7c3fbd240ad554c225598843e75f2b0001cf2c50R131-R134
because removing all the labels instead just the offending ones, can cause problems in case
in the future there will be labels we do want to keep.

Environment:

@kubevirt-bot
Copy link
Collaborator

Issues go stale after 90d of inactivity.
Mark the issue as fresh with /remove-lifecycle stale.
Stale issues rot after an additional 30d of inactivity and eventually close.

If this issue is safe to close now please do so with /close.

/lifecycle stale

@kubevirt-bot kubevirt-bot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Oct 15, 2023
@oshoval
Copy link
Collaborator Author

oshoval commented Nov 12, 2023

/remove-lifecycle stale

@kubevirt-bot kubevirt-bot removed the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Nov 12, 2023
@kubevirt-bot
Copy link
Collaborator

Issues go stale after 90d of inactivity.
Mark the issue as fresh with /remove-lifecycle stale.
Stale issues rot after an additional 30d of inactivity and eventually close.

If this issue is safe to close now please do so with /close.

/lifecycle stale

@kubevirt-bot kubevirt-bot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Feb 10, 2024
@oshoval
Copy link
Collaborator Author

oshoval commented Feb 11, 2024

/remove-lifecycle stale

@kubevirt-bot kubevirt-bot removed the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Feb 11, 2024
@kubevirt-bot
Copy link
Collaborator

Issues go stale after 90d of inactivity.
Mark the issue as fresh with /remove-lifecycle stale.
Stale issues rot after an additional 30d of inactivity and eventually close.

If this issue is safe to close now please do so with /close.

/lifecycle stale

@kubevirt-bot kubevirt-bot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label May 11, 2024
@kubevirt-bot
Copy link
Collaborator

Stale issues rot after 30d of inactivity.
Mark the issue as fresh with /remove-lifecycle rotten.
Rotten issues close after an additional 30d of inactivity.

If this issue is safe to close now please do so with /close.

/lifecycle rotten

@kubevirt-bot kubevirt-bot added lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. and removed lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. labels Jun 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed.
Projects
None yet
Development

No branches or pull requests

2 participants