A pod never terminated if a container image registry was unavailable

This commit is contained in:
derekwaynecarr
2016-04-01 13:39:19 -04:00
parent 5e159695d9
commit eeeccd0a67
3 changed files with 4 additions and 3 deletions

View File

@@ -122,7 +122,7 @@ func (puller *serializedImagePuller) PullImage(pod *api.Pod, container *api.Cont
puller.logIt(ref, api.EventTypeWarning, FailedToPullImage, logPrefix, fmt.Sprintf("Failed to pull image %q: %v", container.Image, err), glog.Warning)
puller.backOff.Next(backOffKey, puller.backOff.Clock.Now())
if err == RegistryUnavailable {
msg := fmt.Sprintf("image pull failed for %s because the registry is temporarily unavailable.", container.Image)
msg := fmt.Sprintf("image pull failed for %s because the registry is unavailable.", container.Image)
return err, msg
} else {
return ErrImagePull, err.Error()