-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
[Question] Is there a way to cordon control-plane nodes by default? #18497
Comments
It is not recommended to schedule pods on control plane Node. The control-plane node runs pods with critical services, thus by default, Kubernetes clusters don't schedule pods on the control-plane node for security reasons issues. |
/kind support |
Indeed. Which is why I'm asking this question in the first place. I'm asking for a way to have |
oh. I understand. I agree and the value of " node-role.kubernetes.io/control-plane=" is empty. |
Understood. And thank you for your response. |
It is still a good feature for multi-node, to avoid removing the taint if there is more than one node. EDIT: this is supposed to already be the case. Maybe "NoSchedule" vs "SchedulingDisabled" ? // primary control-plane and worker nodes should be untainted by default
if n.ControlPlane && !config.IsPrimaryControlPlane(cfg, n) { There are some pods that are scheduled on the control plane node, i.e. the control plane pods |
@anthony-S93 How about a flag in the beginning |
Even if i understand the reasoning behind the untainted control plane , if the NoSchedule is present by default, it will help in understanding the prod level work to new developers trying minikube. |
Yeah I had this issue in minikube as well. I was trying to learn how hard antiAffinity works with replication redis and after making several other configs I ended up having one of the replicas scheduled on the control plane so I had to taint that node. |
If we start a multi-node cluster like so:
$ minikube start -n 5 -p some-cluster
The control-plane node in the cluster will not have
SchedulingDisabled
status by default. As a result, we have to runkubectl cordon
manually to set that status.Is there a way to enable this by default?
The text was updated successfully, but these errors were encountered: