-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Description
Enhancement Description
Currently, Kubernetes tolerations and NodeAffinity rules lack semantic versioning support. This feature will allow filtering based on semver ranges (e.g., >=v1.26.0) by adding new comparison operators:
- SemverLt
- SemverGt
- SemverEq
This enables clean support for firmware checks, Kubernetes version preferences, and other semver-based scheduling use cases.
Examples
Tolerations
tolerations:
- key: "node.kubernetes.io/kubelet-version"
operator: "SemverGt"
value: "v1.28.0"NodeAffinity
nodeAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
nodeSelectorTerms:
- matchExpressions:
- key: "kubeletVersion"
operator: "SemverEq"
values: ["v1.28.0"]Background
Current KEP #5471 focuses on integer operators only compliance for SLA/failure-probability for tolerations by adding Gt and Lt operators. Similarly this enhancement will involve parsing semantic versioning and using the new operators to support various scenarios, for example:
- Comparing node kubelet versions (e.g., feature gating)
- Firmware version targeting for device scheduling
/sig scheduling
/sig apps
- One-line enhancement description (can be used as a release note): Add Semantic Version Comparison operators to Tolerations and NodeAffinity.
- Discussion Link:
- PRs by stage and milestone:
- Alpha - v1.xx
- KEP (
k/enhancements) update PR(s): - Code (
k/k) update PR(s): - Docs (
k/website) update PR(s):
- KEP (
- Alpha - v1.xx
Please keep this description up to date. This will help the Enhancement Team to track the evolution of the enhancement efficiently.
Metadata
Metadata
Assignees
Labels
Type
Projects
Status
Status