1
0
Эх сурвалжийг харах

Include error message in pull warning/errors

Signed-off-by: Felix Fontein <[email protected]>
Felix Fontein 1 жил өмнө
parent
commit
2e85b3c265
1 өөрчлөгдсөн 8 нэмэгдсэн , 6 устгасан
  1. 8 6
      pkg/compose/pull.go

+ 8 - 6
pkg/compose/pull.go

@@ -200,18 +200,20 @@ func (s *composeService) pullServiceImage(ctx context.Context, service types.Ser
 	// then the status should be warning instead of error
 	if err != nil && service.Build != nil {
 		w.Event(progress.Event{
-			ID:     service.Name,
-			Status: progress.Warning,
-			Text:   "Warning",
+			ID:         service.Name,
+			Status:     progress.Warning,
+			Text:       "Warning",
+			StatusText: err.Error(),
 		})
 		return "", WrapCategorisedComposeError(err, PullFailure)
 	}
 
 	if err != nil {
 		w.Event(progress.Event{
-			ID:     service.Name,
-			Status: progress.Error,
-			Text:   "Error",
+			ID:         service.Name,
+			Status:     progress.Error,
+			Text:       "Error",
+			StatusText: err.Error(),
 		})
 		return "", WrapCategorisedComposeError(err, PullFailure)
 	}