Skip to content
This repository has been archived by the owner on Dec 11, 2023. It is now read-only.

Use node affinity to schedule pods on supported platforms #199

Merged
merged 2 commits into from
Feb 4, 2020

Conversation

lrgar
Copy link
Contributor

@lrgar lrgar commented Feb 3, 2020

The beta.kubernetes.io/arch and beta.kubernetes.io/os labels have been deprecated, and kubernetes.io-named labels, added on Kubernetes 1.14, are now recommended instead.

This PR replaces the node selectors using the old labels with node affinity for more flexibility so that we can handle both old and new Kubernetes versions, once the beta-labels are removed (Kubernetes 1.18, supposedly.)

Technically, this is a breaking change, since customers can't now use a beta.kubernetes.io/os value other than linux since the affinity is not currently customizable on the CR. Although, is this an actual use case?

Either way, we should support custom affinities on the CR, but I'll leave it for a later PR.

Kubernetes 1.18+ is expected to drop the "beta.kubernetes.io" labels,

https://github.com/kubernetes/kubernetes/blob/master/CHANGELOG-1.14.md#deprecations

This is in favor of "kubernetes.io" which was added on 1.14. This commit replaces the node selectors using the old labels with node affinity for more flexibility.
@lrgar lrgar requested review from mmayr-at and DTMad February 3, 2020 13:01
@lrgar lrgar merged commit 5eb7c58 into master Feb 4, 2020
@lrgar lrgar deleted the feature/node-affinity branch February 4, 2020 08:04
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants