aboutsummaryrefslogtreecommitdiff
path: root/cmd/podman/images.go
diff options
context:
space:
mode:
Diffstat (limited to 'cmd/podman/images.go')
-rw-r--r--cmd/podman/images.go21
1 files changed, 13 insertions, 8 deletions
diff --git a/cmd/podman/images.go b/cmd/podman/images.go
index 2dcd743cf..846f00c98 100644
--- a/cmd/podman/images.go
+++ b/cmd/podman/images.go
@@ -182,15 +182,20 @@ func getImagesTemplateOutput(runtime *libpod.Runtime, images []inspect.ImageResu
if !opts.noTrunc {
imageID = shortID(img.ID)
}
- params := imagesTemplateParams{
- Repository: img.Repository,
- Tag: img.Tag,
- ID: imageID,
- Digest: img.Digest,
- Created: units.HumanDuration(time.Since((createdTime))) + " ago",
- Size: units.HumanSizeWithPrecision(float64(*img.Size), 3),
+ // get all specified repo:tag pairs and print them separately
+ for repo, tags := range libpod.ReposToMap(img.RepoTags) {
+ for _, tag := range tags {
+ params := imagesTemplateParams{
+ Repository: repo,
+ Tag: tag,
+ ID: imageID,
+ Digest: img.Digest,
+ Created: units.HumanDuration(time.Since((createdTime))) + " ago",
+ Size: units.HumanSizeWithPrecision(float64(*img.Size), 3),
+ }
+ imagesOutput = append(imagesOutput, params)
+ }
}
- imagesOutput = append(imagesOutput, params)
}
return
}