mirror of
https://github.com/containrrr/watchtower.git
synced 2025-09-22 05:40:50 +02:00
fix: return nil imageinfo when retrieve fails (#680)
This commit is contained in:
parent
30b51c4b45
commit
64d48b70c2
1 changed files with 1 additions and 0 deletions
|
@ -122,6 +122,7 @@ func (client dockerClient) GetContainer(containerID string) (Container, error) {
|
|||
imageInfo, _, err := client.api.ImageInspectWithRaw(bg, containerInfo.Image)
|
||||
if err != nil {
|
||||
log.Warnf("Failed to retrieve container image info: %v", err)
|
||||
return Container{containerInfo: &containerInfo, imageInfo: nil}, nil
|
||||
}
|
||||
|
||||
return Container{containerInfo: &containerInfo, imageInfo: &imageInfo}, nil
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue