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

Add ClusterFeatureCCMClusterName feature for OpenStack clusters #7330

Merged

Conversation

xmudrii
Copy link
Member

@xmudrii xmudrii commented Jul 2, 2021

What this PR does / why we need it:

This PR introduces a cluster feature called ccmClusterName, which is used to apply the --cluster-name flag on the external CCMs. Currently, this flag is only applied on the OpenStack CCM. In the future, it will be applied for the other cloud providers that support the external CCM as well.

The --cluster-name flag is often used for naming cloud resources, such as Load Balancers. If it's not provided, the CCM would default it to kubernetes.

Not providing the cluster-name flag can cause conflicts as described in issue #7229.

It's not possible to easily change this flag for the existing user clusters, as it can cause the external CCM to lose track of the existing cloud resources. Therefore, we're introducing a feature flag with the following behavior:

  • if it's enabled, add the --cluster-name flag on the external CCM deployment
  • enable the flag by default for newly created clusters
  • allow users to explicitly enable this flag for the existing clusters
    • in this case, it's up to the user to clean up any leftover resources
    • in the future, we might implement a migration mechanism that would automatically clean up leftover resources

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 #7332

Does this PR introduce a user-facing change?:

Add ClusterFeatureCCMClusterName feature for OpenStack clusters. This feature adds the --cluster-name flag to the OpenStack external CCM deployment. The feature gate is enabled by default for newly created clusters. Enabling this feature gate for existing clusters can cause the external CCM to lose the track of the existing cloud resources, so it's up to the users to clean up any leftover resources.

/assign @kron4eg

@xmudrii xmudrii requested a review from kron4eg July 2, 2021 11:27
@kubermatic-bot kubermatic-bot added release-note Denotes a PR that will be considered when it comes time to generate release notes. dco-signoff: yes Denotes that all commits in the pull request have the valid DCO signoff message. sig/api Denotes a PR or issue as being assigned to SIG API. sig/cluster-management Denotes a PR or issue as being assigned to SIG Cluster Management. size/S Denotes a PR that changes 10-29 lines, ignoring generated files. labels Jul 2, 2021
Copy link
Member

@kron4eg kron4eg left a comment

Choose a reason for hiding this comment

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

/approve

@kubermatic-bot kubermatic-bot added the lgtm Indicates that a PR is ready to be merged. label Jul 2, 2021
@kubermatic-bot
Copy link
Contributor

LGTM label has been added.

Git tree hash: 4c236699306ba6af379ab7669bc250d334b7ad05

@kron4eg
Copy link
Member

kron4eg commented Jul 2, 2021

@xmudrii looks like we also need someone from sig-api

Signed-off-by: Marko Mudrinić <mudrinic.mare@gmail.com>
@xmudrii xmudrii force-pushed the feature-flag-cluster-name branch from cbcc72c to 9f50962 Compare July 2, 2021 11:39
@kubermatic-bot kubermatic-bot removed the lgtm Indicates that a PR is ready to be merged. label Jul 2, 2021
@kron4eg
Copy link
Member

kron4eg commented Jul 2, 2021

/lgtm

@kubermatic-bot kubermatic-bot added the lgtm Indicates that a PR is ready to be merged. label Jul 2, 2021
@kubermatic-bot
Copy link
Contributor

LGTM label has been added.

Git tree hash: 90b84c93bbf9a4414457c6c54d1c5816e5308e40

@maciaszczykm
Copy link
Contributor

/approve

@kubermatic-bot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: kron4eg, maciaszczykm, xmudrii

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

@kubermatic-bot kubermatic-bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jul 2, 2021
@kubermatic-bot kubermatic-bot merged commit db674db into kubermatic:master Jul 2, 2021
@xmudrii xmudrii deleted the feature-flag-cluster-name branch July 2, 2021 13:02
@xmudrii
Copy link
Member Author

xmudrii commented Jul 2, 2021

/cherry-pick release/v2.17

@xmudrii
Copy link
Member Author

xmudrii commented Jul 2, 2021

/cherry-pick release/v2.16

@kubermatic-bot
Copy link
Contributor

@xmudrii: new pull request created: #7335

In response to this:

/cherry-pick release/v2.17

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/test-infra repository.

@kubermatic-bot
Copy link
Contributor

@xmudrii: new pull request created: #7336

In response to this:

/cherry-pick release/v2.16

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/test-infra repository.

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. dco-signoff: yes Denotes that all commits in the pull request have the valid DCO signoff message. lgtm Indicates that a PR is ready to be merged. release-note Denotes a PR that will be considered when it comes time to generate release notes. sig/api Denotes a PR or issue as being assigned to SIG API. sig/cluster-management Denotes a PR or issue as being assigned to SIG Cluster Management. size/S Denotes a PR that changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Implement a feature flag to enable the --cluster-name flag
4 participants