mirror of
https://github.com/k3s-io/kubernetes.git
synced 2026-01-04 23:17:50 +00:00
Keep backward compatibility for 'node.Spec.Unschedulable'.
Signed-off-by: Da K. Ma <klaus1982.cn@gmail.com>
This commit is contained in:
@@ -199,10 +199,13 @@ func ApplyFeatureGates() {
|
||||
|
||||
// Fit is determined based on whether a pod can tolerate all of the node's taints
|
||||
factory.RegisterMandatoryFitPredicate(predicates.PodToleratesNodeTaintsPred, predicates.PodToleratesNodeTaints)
|
||||
// Fit is determined based on whether a pod can tolerate unschedulable of node
|
||||
factory.RegisterMandatoryFitPredicate(predicates.CheckNodeUnschedulablePred, predicates.CheckNodeUnschedulablePredicate)
|
||||
// Insert Key "PodToleratesNodeTaints" and "CheckNodeUnschedulable" To All Algorithm Provider
|
||||
// The key will insert to all providers which in algorithmProviderMap[]
|
||||
// if you just want insert to specific provider, call func InsertPredicateKeyToAlgoProvider()
|
||||
factory.InsertPredicateKeyToAlgorithmProviderMap(predicates.PodToleratesNodeTaintsPred)
|
||||
factory.InsertPredicateKeyToAlgorithmProviderMap(predicates.CheckNodeUnschedulablePred)
|
||||
|
||||
glog.Warningf("TaintNodesByCondition is enabled, PodToleratesNodeTaints predicate is mandatory")
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user