Skip to content

Commit 23f0c15

Browse files
authored
Merge pull request #31986 from PriyanshuAhlawat/noteForNodeRestriction
Added note about noderestriction labels issue-#31972
2 parents cffda78 + 2198d0f commit 23f0c15

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

content/en/docs/setup/production-environment/tools/kubeadm/create-cluster-kubeadm.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -284,6 +284,15 @@ If your network is not working or CoreDNS is not in the `Running` state, check o
284284
[troubleshooting guide](/docs/setup/production-environment/tools/kubeadm/troubleshooting-kubeadm/)
285285
for `kubeadm`.
286286

287+
### Managed node labels
288+
289+
By default, kubeadm enables the [NodeRestriction](/docs/reference/access-authn-authz/admission-controllers/#noderestriction)
290+
admission controller that restricts what labels can be self-applied by kubelets on node registration.
291+
The admission controller documentation covers what labels are permitted to be used with the kubelet `--node-labels` option.
292+
The `node-role.kubernetes.io/control-plane` label is such a restricted label and kubeadm manually applies it using
293+
a privileged client after a node has been created. To do that manually you can do the same by using `kubectl label`
294+
and ensure it is using a privileged kubeconfig such as the kubeadm managed `/etc/kubernetes/admin.conf`.
295+
287296
### Control plane node isolation
288297

289298
By default, your cluster will not schedule Pods on the control-plane node for security

0 commit comments

Comments
 (0)