Skip to content

Instantly share code, notes, and snippets.

@abstractmachines
Last active August 13, 2021 01:34
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save abstractmachines/47b17cd028325ab78b1ee1d23d8c6794 to your computer and use it in GitHub Desktop.
Save abstractmachines/47b17cd028325ab78b1ee1d23d8c6794 to your computer and use it in GitHub Desktop.
taints, tolerations and node affinity

Taints, tolerations and node affinity : the e-magnetism of Kubernetes Nodes in the Kube Scheduler

We can think of Node Affinity as analagous analogus to magnetic attraction;

We can think of Node Taints as the complement of that (magnetic repulsion);

We can think of the determinant of a Node's eventual location as being "up to the Kube scheduler.

That's why we'll often have an effect of NoSchedule for nodes we'll want an exception of sorts for.

The scheduler

"The scheduler checks taints, not node conditions, when it makes scheduling decisions." K8s docs

The control plane taints

"The control plane, using the node controller, automatically creates taints with a NoSchedule effect for node conditions." K8s docs

DaemonSet taints

"node.kubernetes.io/unschedulable:NoSchedule toleration is added automatically to DaemonSet Pods."

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment