Skip to content

Commit

Permalink
fix comment
Browse files Browse the repository at this point in the history
  • Loading branch information
alexmasi committed May 28, 2024
1 parent cdda7ad commit db85d87
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions deploy/deploy.go
Original file line number Diff line number Diff line change
Expand Up @@ -465,10 +465,10 @@ func (k *KubeadmSpec) Deploy(ctx context.Context) error {
log.Infof("Creating kubeadm cluster with: %v", args)
if out, err := run.OutLogCommand("sudo", args...); err != nil {
msg := []string{}
// Filter output to only show lines relevant to the error message. For kind these are lines
// prefixed with "ERROR" or "Command Output".
// Filter output to only show lines relevant to the error message. For kubeadm these are lines
// containing "error" in any case.
for _, line := range strings.Split(string(out), "\n") {
if strings.HasPrefix(line, "ERROR") || strings.HasPrefix(line, "Command Output") {
if strings.Contains(strings.ToLower(line), "error") {
msg = append(msg, line)
}
}
Expand Down

0 comments on commit db85d87

Please sign in to comment.