-
Notifications
You must be signed in to change notification settings - Fork 716
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
kubeadm init should not set --allow-privileges=true in the default generated kube-apiserver.yaml manifest #2190
Comments
/priority awaiting-more-evidence @brianpursley as mentioned on slack, i'd like to understand all the side-effects of as can be seen here: kubeadm deploys the kube-proxy containers as priviliged. does this mean that kube-proxy will no longer work with kubeadm? also how about the static pods for the rest of the control-plane components? |
OK. From what I know, this controls whether or not you are allowed to use I don't know if it has any effects internally. If changing this setting breaks the system, then I think maybe I will end up creating a different issue to remove the setting from apiserver 😁 |
yes, my understanding as well. which means that toggling this to false, breaks the kubeadm control-plane and kube-proxy deployment.
if someone can manage to get their cluster to run with this option set to here we explored the complexity of not running the control-plane as priviliged and we faced a number of blockers: also not sure how we can solve this for kube-proxy anytime soon, given the demands it has. |
OK I see what you're saying. when I look at one of my kube proxies, it has this in it:
That does seem to make it more complicated to turn off. |
@brianpursley i'm going to close this because we don't have a clear proposal in place. thanks. |
@neolit123 no problem, I understand. Thanks for explaining to me about kube-proxy |
Is this a BUG REPORT or FEATURE REQUEST?
FEATURE REQUEST
Versions
kubeadm version (use
kubeadm version
):Environment:
kubectl version
):uname -a
):What happened?
I created a cluster using
kubeadm init
and it set--allow-privileged=true
when based on the documentation, I thought that my cluster would not allow privileged by default.What you expected to happen?
According to the documentation, the default value for
--allow-privileged
flag of apiserver is false.But when you use kubeadm to initialize your cluster, it explicitly sets
--allow-privileged=true
in the generated kube-apiserver.yaml.People should check and be aware of the settings in the configs of their own cluster, but this is a little surprising given that the documented default is false.
I am proposing that kubeadm should choose the more secure default (false) and require people to explicitly enable --allow-privileged on their cluster if they want it.
How to reproduce it (as minimally and precisely as possible)?
Anything else we need to know?
I made an initial (simple) attempt at this with kubernetes/kubernetes#92381, but soon discovered that kind depends on kubeadm init setting --allow-privileged=true, which is needed for kind to work. Please be aware that changing this might require some coordination with the kind repo to make sure it is still able to init a cluster with allow-privileges=true.
Maybe a flag could be added to kubeadm init that would like kind (or others) request this setting if they really want it, but it should be an opt-in thing.
The text was updated successfully, but these errors were encountered: