Merge pull request #86733 from oomichi/add-debugging-msg

Add debugging message to know the pod status
This commit is contained in:
Kubernetes Prow Robot 2019-12-30 18:53:39 -08:00 committed by GitHub
commit adf056230a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -184,10 +184,13 @@ func podRunningAndReady(c clientset.Interface, podName, namespace string) wait.C
}
switch pod.Status.Phase {
case v1.PodFailed, v1.PodSucceeded:
e2elog.Logf("The status of Pod %s is %s which is unexpected", podName, pod.Status.Phase)
return false, conditions.ErrPodCompleted
case v1.PodRunning:
e2elog.Logf("The status of Pod %s is %s (Ready = %v)", podName, pod.Status.Phase, podutil.IsPodReady(pod))
return podutil.IsPodReady(pod), nil
}
e2elog.Logf("The status of Pod %s is %s, waiting for it to be Running (with Ready = true)", podName, pod.Status.Phase)
return false, nil
}
}