Running pods on master nodes in RKE
You may run into situations where you need to run pods on your K8s master node. If you’r using RKE, you need to taint two labels on the controller/master node.
You can obtain the current labels using
kubectl describe node NODENAME
and look under the labels section
Labels: beta.kubernetes.io/arch=amd64 beta.kubernetes.io/os=linux kubernetes.io/arch=amd64 kubernetes.io/hostname=lab-1 kubernetes.io/os=linux node-role.kubernetes.io/controlplane=true node-role.kubernetes.io/etcd=true
you then need the following two commands
kubectl taint nodes node-1 node-role.kubernetes.io/etcd- kubectl taint nodes node-1 node-role.kubernetes.io/controlplane-
Happy Kuberneting!
Leave a Reply