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

chore(cluster-autoscaler/rancher): parametize provider ID #5320

Closed
wants to merge 3 commits into from

Conversation

alcidesmig
Copy link

Which component this PR applies to?

cluster-autoscaler

What type of PR is this?

/kind feature

What this PR does / why we need it:

This PR parametrizes the Provider ID used in rancher autoscaler to attribute node group to existent nodes.

Which issue(s) this PR fixes:

Fixes #5140

Does this PR introduce a user-facing change?

NONE

Additional documentation e.g., KEPs (Kubernetes Enhancement Proposals), usage docs, etc.:

@k8s-ci-robot k8s-ci-robot added the kind/feature Categorizes issue or PR as related to a new feature. label Nov 18, 2022
@linux-foundation-easycla
Copy link

linux-foundation-easycla bot commented Nov 18, 2022

CLA Signed

The committers listed above are authorized under a signed CLA.

@k8s-ci-robot
Copy link
Contributor

Welcome @alcidesmig!

It looks like this is your first PR to kubernetes/autoscaler 🎉. Please refer to our pull request process documentation to help your PR have a smooth ride to approval.

You will be prompted by a bot to use commands during the review process. Do not be afraid to follow the prompts! It is okay to experiment. Here is the bot commands documentation.

You can also check if kubernetes/autoscaler has its own contribution guidelines.

You may want to refer to our testing guide if you run into trouble with your tests not passing.

If you are having difficulty getting your pull request seen, please follow the recommended escalation practices. Also, for tips and tricks in the contribution process you may want to read the Kubernetes contributor cheat sheet. We want to make sure your contribution gets all the attention it needs!

Thank you, and welcome to Kubernetes. 😃

@k8s-ci-robot k8s-ci-robot added cncf-cla: no Indicates the PR's author has not signed the CNCF CLA. size/S Denotes a PR that changes 10-29 lines, ignoring generated files. labels Nov 18, 2022
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: alcidesmig
Once this PR has been reviewed and has the lgtm label, please assign feiskyer for approval by writing /assign @feiskyer in a comment. For more information see the Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found 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 cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. and removed cncf-cla: no Indicates the PR's author has not signed the CNCF CLA. labels Nov 18, 2022
@alcidesmig
Copy link
Author

@feiskyer @x13n can you take a look?

@mwielgus
Copy link
Contributor

mwielgus commented Dec 5, 2022

@ctrox
Copy link
Contributor

ctrox commented Dec 5, 2022

Thanks @alcidesmig for your PR!

Unfortunately the prefix alone won't fix the issues described in #5140 (comment). For example, for AWS the ProviderID is in the following format: aws:///region/instance-id. So even if we allow the provider to continue here with an aws:/// prefixed ProviderID, it will just fail in the next step where we try to extract the node group name from the node name. For most RKE2 providers, this is sadly not <cluster-name>-<node group name>-<random int>-<random string> as assumed by the code. So I'm not sure how much this PR would actually fix as I'm not aware of any RKE2 providers where the ProviderID has a different prefix but the node name adheres to the assumed "standard". Or do you know of any that work like that @alcidesmig?

In order to fix this issue properly, I think this whole thing needs to be approached differently. I would prefer if the user would not have to worry about configuring this and the provider would just figure everything out by itself. I have already started to work on this but I have not been able to finish it yet as the tests need to be adjusted quite a bit as well. I realize that this is probably not easy to just pick up but if you can wait, I intend to take some time this week to finish this.

@alcidesmig
Copy link
Author

Hi, @ctrox!

Got it. I implemented this PR because we're having problems with openstack://<uuid> prefix and, for us, it solves the problem. I agree with you about the "not relying on provider id" and can wait for your solution. If you need help coding it, please let me know.

Thank you for bringing it.

@ctrox
Copy link
Contributor

ctrox commented Dec 9, 2022

Opened PR #5361 that should handle this issue more generally.

@k8s-ci-robot k8s-ci-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Dec 12, 2022
@k8s-ci-robot
Copy link
Contributor

@alcidesmig: PR needs rebase.

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.

@alcidesmig
Copy link
Author

Thank you @ctrox! Closing here...

@alcidesmig alcidesmig closed this Dec 12, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/cluster-autoscaler cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. kind/feature Categorizes issue or PR as related to a new feature. needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. 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.

Cannot deploy cluster-autoscaler with Rancher RKE2
5 participants