Skip to content

Commit

Permalink
Merge pull request #75523 from freehan/bug-fix
Browse files Browse the repository at this point in the history
reconcile pod ready condition when message is not expected
  • Loading branch information
k8s-ci-robot committed Apr 5, 2019
2 parents e9ca60b + 47bc948 commit a727bdd
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pkg/kubelet/status/status_manager.go
Expand Up @@ -665,8 +665,8 @@ func NeedToReconcilePodReadiness(pod *v1.Pod) bool {
}
podReadyCondition := GeneratePodReadyCondition(&pod.Spec, pod.Status.Conditions, pod.Status.ContainerStatuses, pod.Status.Phase)
i, curCondition := podutil.GetPodConditionFromList(pod.Status.Conditions, v1.PodReady)
// Only reconcile if "Ready" condition is present
if i >= 0 && curCondition.Status != podReadyCondition.Status {
// Only reconcile if "Ready" condition is present and Status or Message is not expected
if i >= 0 && (curCondition.Status != podReadyCondition.Status || curCondition.Message != podReadyCondition.Message) {
return true
}
return false
Expand Down

0 comments on commit a727bdd

Please sign in to comment.