-
Notifications
You must be signed in to change notification settings - Fork 289
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
Update validation for the cluster name length #8046
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #8046 +/- ##
=======================================
Coverage 73.44% 73.44%
=======================================
Files 577 577
Lines 35878 35878
=======================================
Hits 26351 26351
Misses 7861 7861
Partials 1666 1666 ☔ View full report in Codecov by Sentry. |
// to get the KinD cluster's name and on top of this, KinD also adds a "-control-plane suffix" to | ||
// the cluster name to arrive at the name for the control plane node (container), which makes the | ||
// control plane node name 64 characters in length. | ||
if len(clusterName) > 35 { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If Kind does limit the length only after 50 characters and we append "-eks-a-cluster" which is 14 characters in length shouldn't we check for > 36 here.? did you want to have a buffer just in case?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if the cluster name length is exactly 36 characters, then kubeadm init fails with a 404 Not Found error when making a GET request to the control plane node. I am not exactly sure why that happens but one possible reason could be that the node might be having a label name which exceeds 63 characters as labels have a limit of 63 characters.
/lgtm |
/approve |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: sp1999 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 |
/cherry-pick release-0.19 |
@sp1999: new pull request created: #8050 In response to this:
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. |
Issue #, if available:
#7302
#8016
Description of changes:
Updated the cluster config validation for the cluster name length to be not more than 35 characters.
Testing (if applicable):
Tested locally with a cluster name length of more than 35 characters on docker provider
Documentation added/planned (if applicable):
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.