diff --git a/pkg/client/node.go b/pkg/client/node.go index 901cda7b..e41bf75f 100644 --- a/pkg/client/node.go +++ b/pkg/client/node.go @@ -811,6 +811,11 @@ func NodeWaitForLogMessage(ctx context.Context, runtime runtimes.Runtime, node * break } } + + running, status, err := runtime.GetNodeStatus(ctx, node) + if err == nil { + return fmt.Errorf("%v: node %s is running=%v in status=%s", errMsg, node.Name, running, status) + } return errMsg } diff --git a/pkg/runtimes/runtime.go b/pkg/runtimes/runtime.go index 5015e5ee..050490e1 100644 --- a/pkg/runtimes/runtime.go +++ b/pkg/runtimes/runtime.go @@ -55,7 +55,7 @@ type Runtime interface { RenameNode(context.Context, *k3d.Node, string) error GetNodesByLabel(context.Context, map[string]string) ([]*k3d.Node, error) GetNode(context.Context, *k3d.Node) (*k3d.Node, error) - GetNodeStatus(context.Context, *k3d.Node) (bool, string, error) + GetNodeStatus(context.Context, *k3d.Node) (bool, string, error) // returns (running, status, error) GetNodesInNetwork(context.Context, string) ([]*k3d.Node, error) CreateNetworkIfNotPresent(context.Context, *k3d.ClusterNetwork) (*k3d.ClusterNetwork, bool, error) // @param context, name - @return NETWORK, EXISTS, ERROR GetKubeconfig(context.Context, *k3d.Node) (io.ReadCloser, error)