mirror of
https://github.com/kubernetes-sigs/descheduler.git
synced 2026-01-26 05:14:13 +01:00
Redefine IsEvictable to be customizable for a particular strategy
Use WithXXX methods to extend the list of constraints to also provide a reasonable error message.
This commit is contained in:
@@ -109,9 +109,15 @@ func IsCriticalPod(pod *v1.Pod) bool {
|
||||
if IsStaticPod(pod) {
|
||||
return true
|
||||
}
|
||||
|
||||
if IsMirrorPod(pod) {
|
||||
return true
|
||||
}
|
||||
|
||||
if pod.Spec.Priority != nil && *pod.Spec.Priority >= SystemCriticalPriority {
|
||||
return true
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user