Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

driver/daemonset: Align node selection behavior with Kubernetes scheduler #1958

Merged
merged 7 commits into from
Sep 17, 2024

Conversation

nonylene
Copy link
Contributor

@nonylene nonylene commented Feb 5, 2024

What this PR does / why we need it:

Align node selection behavior with Kubernetes scheduler in DaemonSet driver.

Which issue(s) this PR fixes

Special notes for your reviewer:

Release note:

Align node selection behavior with Kubernetes scheduler in DaemonSet driver.

Align node filter behavior with Kuberntes scheduler
to avoid errors when both of nodeSelctor and nodeAffinity are set
to PodSpec.

> If you specify both nodeSelector and nodeAffinity, both must be satisfied for the Pod to be scheduled onto a node.
>
> https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/

Issue: vmware-tanzu#1957
Signed-off-by: nonylene <nonylene@gmail.com>
Align nodeAffinity matching behavior with Kubernetes schduler.

> If you specify multiple expressions in a single matchExpressions field associated with a term in nodeSelectorTerms, then the Pod can be scheduled onto a node only if all the expressions are satisfied (expressions are ANDed).
>
> https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/

Close vmware-tanzu#1957

Signed-off-by: nonylene <nonylene@gmail.com>
@franknstyle franknstyle self-requested a review June 27, 2024 09:35
@franknstyle franknstyle merged commit 7700f31 into vmware-tanzu:main Sep 17, 2024
20 checks passed
@nonylene nonylene deleted the fix-node-selection branch September 17, 2024 02:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Node selector / Node affinity behavior is inconsistent with Kubernetes Scheduler
2 participants