The kubernetes master have the taint which will not schedlue the normal workloads on the master. But it schedules the pods on the master though it has the taint applied as noschedule.
How is this possible, is the k8s environment behaving differently or my understanding wrong. I expect, the master should allow the pods to be scheduled only after removing the taint on the master.
apiVersion: v1
kind: Pod
metadata:
name: nginx
spec:
containers:
- image: nginx
name: nginx
nodeName: masterWhile taints are meant to be a way for a Node to repel some Pods, when you explicitly provide nodeName in PodSpec, it takes precedence over the other methods for node selection (taints and tolerations, etc.) and Kubernetes scheduler actually short circuits the process of scheduling by directly assigning the Pod to that node.
However, as docs mentions, after assigning a Pod to a Node, it may fail to run because of resource limitations. But the scheduling job is done.