The toleration
fields are both set by kubernetes on any pod by default. This controls when a pod is restarted on a new node if the current node crashes or becomes unreachable. See https://kubernetes.io/docs/concepts/scheduling-eviction/taint-and-toleration/#taint-based-evictions for more information.
I can't say for sure why nodeAffinity
is set, but it might be the result of a node mounting a volume that can only be attached from a specific node. Kubernetes would then automatically add nodeAffinity
that matches the volumes constraint. See https://kubernetes.io/docs/concepts/storage/persistent-volumes/#node-affinity.