-
Notifications
You must be signed in to change notification settings - Fork 288
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
Use super-admin Kubeconfig for kube-vip from Kubernetes v1.29 onwards #7368
Conversation
Codecov ReportAttention:
Additional details and impacted files@@ Coverage Diff @@
## main #7368 +/- ##
==========================================
+ Coverage 72.03% 73.47% +1.44%
==========================================
Files 579 579
Lines 44704 36344 -8360
==========================================
- Hits 32202 26705 -5497
+ Misses 10740 7875 -2865
- Partials 1762 1764 +2 ☔ View full report in Codecov by Sentry. |
039d52e
to
1247b0b
Compare
1247b0b
to
9949b9a
Compare
844a806
to
838b69a
Compare
38fa817
to
fec7a56
Compare
fec7a56
to
6764656
Compare
6764656
to
b3f522d
Compare
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.
/approve
/lgtm
/approve
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: abhinavmpandey08 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 |
Before Kubernetes v1.29, the default Kubeconfig file
admin.conf
generated bykubeadm
was bound tosystem:masters
Group. In Kubernetes v1.29, a change was made tokubeadm
to provision a separate Kubeconfig file calledsuper-admin.conf
which is a break-glass Group that can bypass RBAC, and in addition, scoping down theadmin.conf
User's access to the permissions provided by thecluster-admin
ClusterRole
. It is to be noted that in a multi-cluster setup, thesuper-admin.conf
is only created on the primary control plane node, which runskubeadm init
. This causes a bootstrap issue with EKS-A'skube-vip
deployment because the static pod manifest is hardcoded to useadmin.conf
butkube-vip
requires elevated permissions to access the API server during cluster initialization, which are available only when using thesuper-admin.conf
.This issue was first reported by CAPV maintainers in Kubernetes Slack
kube-vip
channel (Initial issue report, Workarounds discussion) when they were trying to add Kubernetes v1.29 support. Since then, the CAPV maintainers have found a workaround that involves using thesuper-admin.conf
only forkubeadm init
and then migrating to using theadmin.conf
after the cluster has been initialized. This PR basically ports the workaround to our cluster templates for EKS-A'skube-vip
deployment to work with Kubernetes v1.29.This is similar to the logic we added to the Bottlerocket kubeadm-bootstrap host container to fix the same issue for clusters using Bottlerocket nodes.
References:
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.