1
0
mirror of https://github.com/kubernetes-sigs/descheduler.git synced 2026-01-26 05:14:13 +01:00

Add check for critical pods to avoid eviction.

This commit is contained in:
Avesh Agarwal
2017-08-29 17:28:18 -04:00
parent 39174159fa
commit 9886ededd1

View File

@@ -73,7 +73,7 @@ func FindDuplicatePods(pods []*v1.Pod) DuplicatePodsMap {
if err != nil || sr == nil {
continue
}
if podutil.IsMirrorPod(pod) || podutil.IsDaemonsetPod(sr) || podutil.IsPodWithLocalStorage(pod) {
if podutil.IsMirrorPod(pod) || podutil.IsDaemonsetPod(sr) || podutil.IsPodWithLocalStorage(pod) || podutil.IsCriticalPod(pod) {
continue
}
s := strings.Join([]string{sr.Reference.Kind, sr.Reference.Namespace, sr.Reference.Name}, "/")