diff --git a/pkg/cloudprovider/cloudprovider.go b/pkg/cloudprovider/cloudprovider.go index c63c258c7974..3fe6b6f2706c 100644 --- a/pkg/cloudprovider/cloudprovider.go +++ b/pkg/cloudprovider/cloudprovider.go @@ -265,6 +265,11 @@ func (c *CloudProvider) RepairPolicies() []cloudprovider.RepairPolicy { ConditionStatus: corev1.ConditionFalse, TolerationDuration: 30 * time.Minute, }, + { + ConditionType: corev1.NodeReady, + ConditionStatus: corev1.ConditionUnknown, + TolerationDuration: 30 * time.Minute, + }, } } diff --git a/test/suites/integration/repair_policy_test.go b/test/suites/integration/repair_policy_test.go index 24b64a62d287..56d464d972b8 100644 --- a/test/suites/integration/repair_policy_test.go +++ b/test/suites/integration/repair_policy_test.go @@ -73,11 +73,16 @@ var _ = Describe("Repair Policy", func() { env.EventuallyExpectNotFound(pod, node) env.EventuallyExpectHealthyPodCount(selector, numPods) }, - Entry("Readiness", corev1.NodeCondition{ + Entry("Node Ready False", corev1.NodeCondition{ Type: corev1.NodeReady, Status: corev1.ConditionFalse, LastTransitionTime: metav1.Time{Time: time.Now().Add(-31 * time.Minute)}, }), + Entry("Node Ready Unknown", corev1.NodeCondition{ + Type: corev1.NodeReady, + Status: corev1.ConditionUnknown, + LastTransitionTime: metav1.Time{Time: time.Now().Add(-31 * time.Minute)}, + }), ) It("should ignore disruption budgets", func() { nodePool.Spec.Disruption.Budgets = []karpenterv1.Budget{