Can I label a worker node before joining Kubernetes master?

12/19/2018

I'd like to prepare multiple yaml files customizing arguments of flannel (DaemonSet) and run the flannel pod of the node with yaml matching the condition expressed by the label. Can I label a worker node before joining Kubernetes master ?

-- shigeru ishida
kubernetes

1 Answer

12/19/2018

You can specify --node-labels when you're kubelet is starting, which will apply the labels to the nodes; but ONLY during registration.

This will not work if your kubelet is starting up and the node is already a member of the cluster.

Kubelet Docs

-- Rawkode
Source: StackOverflow