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

feat: auto-detect clusterendpoint for eks #3363

Merged
merged 26 commits into from
Feb 14, 2023
Merged

Conversation

woehrl01
Copy link
Contributor

@woehrl01 woehrl01 commented Feb 6, 2023

Fixes #3192

Description

Adds auto-detection of the clusterEndpoint if it's eks, based on the provided clusterName.

How was this change tested?

  • manually

Does this change impact docs?

  • Yes, PR includes docs updates
  • Yes, issue opened: #
  • No

Release Note

This release introduces a new feature that automatically detects the cluster endpoint for EKS if it is not set. 

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@netlify
Copy link

netlify bot commented Feb 6, 2023

Deploy Preview for karpenter-docs-prod canceled.

Name Link
🔨 Latest commit 69f6af1
🔍 Latest deploy log https://app.netlify.com/sites/karpenter-docs-prod/deploys/63ea93b220cb9500082bdfd8

@woehrl01 woehrl01 marked this pull request as ready for review February 6, 2023 20:58
@woehrl01 woehrl01 requested a review from a team as a code owner February 6, 2023 20:58
@woehrl01 woehrl01 requested a review from spring1843 February 6, 2023 20:58
@woehrl01
Copy link
Contributor Author

woehrl01 commented Feb 6, 2023

@ellistarn @jonathan-innis Anything else I should add?

@woehrl01
Copy link
Contributor Author

woehrl01 commented Feb 7, 2023

@jonathan-innis I just moved the resolving out of the launchtemplate, the endpoint address is then stored in the settings for the rest of the controllers lifetime.

Copy link
Contributor

@jonathan-innis jonathan-innis left a comment

Choose a reason for hiding this comment

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

LGTM, I think we can just add the clusterEndpoint into the LaunchTemplateProvider constructor

pkg/cloudprovider/cloudprovider.go Outdated Show resolved Hide resolved
pkg/cloudprovider/cloudprovider.go Outdated Show resolved Hide resolved
pkg/cloudprovider/cloudprovider.go Outdated Show resolved Hide resolved
pkg/cloudprovider/cloudprovider.go Outdated Show resolved Hide resolved
woehrl01 and others added 2 commits February 8, 2023 22:30
Co-authored-by: Jonathan Innis <jonathan.innis.ji@gmail.com>
@woehrl01 woehrl01 requested review from jonathan-innis and removed request for spring1843 February 8, 2023 21:58
Copy link
Contributor

@bwagner5 bwagner5 left a comment

Choose a reason for hiding this comment

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

Nice PR! This will be great to reduce the burden of upfront configuration! Just a few suggestions and docs update requests.

pkg/cloudprovider/cloudprovider.go Outdated Show resolved Hide resolved
@woehrl01
Copy link
Contributor Author

woehrl01 commented Feb 9, 2023

Oh, I just saw that auto-formatting changed the layout of the markdown quite significantly, I'll revert the change and update only the single line.

@woehrl01 woehrl01 requested review from bwagner5 and removed request for jonathan-innis February 9, 2023 21:34
Copy link
Contributor

@jonathan-innis jonathan-innis left a comment

Choose a reason for hiding this comment

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

Few comments on the docs changes. Looking good!

charts/karpenter/values.yaml Outdated Show resolved Hide resolved
website/content/en/preview/faq.md Outdated Show resolved Hide resolved
@jonathan-innis
Copy link
Contributor

jonathan-innis commented Feb 10, 2023

Can you also add a unit test (with mocking on the EKS API) to ensure that we are able to resolve this value if it isn't set? If you need any help figuring out where to go for this, you can ping me on Slack or on GH, happy to help.

@woehrl01
Copy link
Contributor Author

@jonathan-innis sure thing, please have a look, if I found the right spots 😄

woehrl01 and others added 2 commits February 11, 2023 01:50
Co-authored-by: Brandon Wagner <bmwagner10@gmail.com>
Copy link
Contributor

@jonathan-innis jonathan-innis left a comment

Choose a reason for hiding this comment

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

LGTM 🚀

Copy link
Contributor

@bwagner5 bwagner5 left a comment

Choose a reason for hiding this comment

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

LGTM

@bwagner5 bwagner5 merged commit 582ca83 into aws:main Feb 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Auto-discover EKS cluster endpoint by cluster name via IRSA
3 participants