Skip to content

Commit

Permalink
clusterctl: check EOF contains in kubectl instead of == (kubernetes-s…
Browse files Browse the repository at this point in the history
…igs#818)

Signed-off-by: Vince Prignano <[email protected]>
  • Loading branch information
vincepri authored and k8s-ci-robot committed Mar 12, 2019
1 parent af298a2 commit abcf6bf
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -765,7 +765,7 @@ func (c *client) waitForKubectlApply(manifest string) error {
klog.V(2).Infof("Waiting for kubectl apply...")
err := c.kubectlApply(manifest)
if err != nil {
if err.Error() == io.EOF.Error() || strings.Contains(err.Error(), "refused") {
if strings.Contains(err.Error(), io.EOF.Error()) || strings.Contains(err.Error(), "refused") {
// Connection was refused, probably because the API server is not ready yet.
klog.V(4).Infof("Waiting for kubectl apply... server not yet available: %v", err)
return false, nil
Expand Down

0 comments on commit abcf6bf

Please sign in to comment.