Merge pull request #15038 from vrothberg/wait-error

container wait: improve error message
This commit is contained in:
OpenShift Merge Robot
2022-07-22 18:51:39 +02:00
committed by GitHub

View File

@ -555,7 +555,7 @@ func (c *Container) WaitForExit(ctx context.Context, pollInterval time.Duration)
// The container never ran.
return true, 0, nil
}
return true, -1, err
return true, -1, fmt.Errorf("%w (container in state %s)", err, c.state.State)
}
return true, exitCode, nil