-
Notifications
You must be signed in to change notification settings - Fork 4.7k
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
metrics-server: enable authenticationTokenWebhook #7200
Comments
Investigating the issue a bit more, a question could be "Do other k8s installers also have this same problem? How do they solve it?"
Kubespray enables both Webhook authentication and authorization for the kubelet. Here's the kubelet-config. root@node1:~# cat /etc/kubernetes/kubelet-config.yaml
eksctl also enables Webhook authentication and authorization for the kubelet. Here's the kubelet-config. root@node1:~# cat /etc/eksctl/kubelet.yaml
It might be kops is aiming for a generic kubernetes installation, which means keeping standard kubernetes default settings. That's potentially a reason to not enable Webhook. However, if --anonymous-auth=false is set, it's indicating "You can't connect anonymously, you must supply authentication credentials". And how will that be done? Most often with service tokens. So, tokens should be allowed. Otherwise, an alternative could be to set --anonymous-auth back to the default of "true". |
* Updated Cluster Role Link: https://github.com/kubernetes-incubator/metrics-server/tree/master/deploy/1.8%2B * Added flags `authentication-token-webhook` and `authorization-mode` to kubelet since `--anonymous-auth` flag is `false` Links: - https://kubernetes.io/docs/reference/command-line-tools-reference/kubelet-authentication-authorization/#kubelet-authentication - https://kubernetes.io/docs/reference/command-line-tools-reference/kubelet-authentication-authorization/#kubelet-authorization - kubernetes/kops#7200 (comment) Signed-off-by: Junaid Ali <[email protected]>
Wow, I had assumed that this would have been fixed in kops v1.13.0 but alas it is not, well not for me on AWS. This "feature" nearly made me change from using kops to something else. I wanted to use the Horizontal Pod Autoscaler and Cluster Autoscaling but could not get the metrics to work and it constantly said ""! For anyone else wanting an easier way to build a new cluster and add these options to get the metrics server up and running then you can do the following during your build:
Adding them at cluster creation time means you do not have to do a rolling update to activate them across the cluster. It took me a few hours to figure that one out ;-) |
Issues go stale after 90d of inactivity. If this issue is safe to close now please do so with Send feedback to sig-testing, kubernetes/test-infra and/or fejta. |
/remove-lifecycle stale |
Can anyone respond whether the defaults for I've experienced this in kops 1.15.1 |
I can confirm that changing the value of those two settings is still required for either metrics-server or kubernetes-dashboard to function on kubernetes 1.17 (and kops 1.17.0-beta.1). I definitely recommend changing the default values as suggested by OP. |
* Updated Cluster Role Link: https://github.com/kubernetes-incubator/metrics-server/tree/master/deploy/1.8%2B * Added flags `authentication-token-webhook` and `authorization-mode` to kubelet since `--anonymous-auth` flag is `false` Links: - https://kubernetes.io/docs/reference/command-line-tools-reference/kubelet-authentication-authorization/#kubelet-authentication - https://kubernetes.io/docs/reference/command-line-tools-reference/kubelet-authentication-authorization/#kubelet-authorization - kubernetes/kops#7200 (comment) Signed-off-by: Junaid Ali <[email protected]>
How i can create cluster with enabled ?
|
Issues go stale after 90d of inactivity. If this issue is safe to close now please do so with Send feedback to sig-testing, kubernetes/test-infra and/or fejta. |
/remove-lifecycle stale |
Per kubernetes-sigs/metrics-server#133 , the metrics-server will not function on kops without these fixes.
kops edit cluster
Although, minimalistically this is sufficient:
Since running a metrics server is pretty common, eliminating the extra steps would be convenient.
Could the settings of "authenticationTokenWebhook: true" and "authorizationMode: Webhook" be configured by default on kops, so the end-user doesn't encounter unexpected errors when deploying metrics?
The text was updated successfully, but these errors were encountered: