Merge pull request #8437 from hiddeco/kube/log-printf

fix(kube): use logger instead of fmt.Printf
This commit is contained in:
Martin Hickey 2020-07-13 17:34:58 +01:00 committed by GitHub
commit 298f574606
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -542,14 +542,14 @@ func (c *Client) waitForPodSuccess(obj runtime.Object, name string) (bool, error
switch o.Status.Phase {
case v1.PodSucceeded:
fmt.Printf("Pod %s succeeded\n", o.Name)
c.Log("Pod %s succeeded", o.Name)
return true, nil
case v1.PodFailed:
return true, errors.Errorf("pod %s failed", o.Name)
case v1.PodPending:
fmt.Printf("Pod %s pending\n", o.Name)
c.Log("Pod %s pending", o.Name)
case v1.PodRunning:
fmt.Printf("Pod %s running\n", o.Name)
c.Log("Pod %s running", o.Name)
}
return false, nil