'Kubernetes NodAffinity Confusion
New to kubernetes and trying to digest the concept of NodeAffinity. The instructions provided at the K8s doc documentation has the following on NodeAffinity :-
- If you specify multiple matchExpressions associated with a single nodeSelectorTerms, then the Pod can be scheduled onto a node only if all the matchExpressions are satisfied.
trying to understand how the multiple matchExpression work and so I created the following pod definition
As you can see I have multiple match expression and only one satisfies the criteria. When I create the pod using the above definition, Scheduler always creates the pod on the matching node which based on my understanding from the documentation it should not. Can someone please provide some guidance here?
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
Solution | Source |
---|