fix(clustertool): improve pod-status checking message and behavior
This commit is contained in:
@@ -44,7 +44,10 @@ func CheckStatus(requiredPods []string, excludePod []string, timeout time.Durati
|
|||||||
// Get pods in all namespaces
|
// Get pods in all namespaces
|
||||||
pods, err := clientset.CoreV1().Pods("").List(context.TODO(), metav1.ListOptions{})
|
pods, err := clientset.CoreV1().Pods("").List(context.TODO(), metav1.ListOptions{})
|
||||||
if err != nil {
|
if err != nil {
|
||||||
log.Error().Err(err).Msg("Error listing pods")
|
log.Debug().Err(err).Msg("Error listing pods")
|
||||||
|
log.Warn().Msg("Cannot recieve pods (yet), waiting before checking again")
|
||||||
|
time.Sleep(5 * time.Second)
|
||||||
|
continue
|
||||||
}
|
}
|
||||||
|
|
||||||
// Check if the required pods are both present and running
|
// Check if the required pods are both present and running
|
||||||
|
|||||||
Reference in New Issue
Block a user