summaryrefslogtreecommitdiff
path: root/cmd/podman/inspect.go
diff options
context:
space:
mode:
Diffstat (limited to 'cmd/podman/inspect.go')
-rw-r--r--cmd/podman/inspect.go4
1 files changed, 4 insertions, 0 deletions
diff --git a/cmd/podman/inspect.go b/cmd/podman/inspect.go
index 84107f3db..ce5a3b823 100644
--- a/cmd/podman/inspect.go
+++ b/cmd/podman/inspect.go
@@ -78,6 +78,10 @@ func inspectCmd(c *cli.Context) error {
inspectType = inspectTypeContainer
}
outputFormat := c.String("format")
+ if strings.Contains(outputFormat, "{{.Id}}") {
+ outputFormat = strings.Replace(outputFormat, "{{.Id}}", formats.IDString, -1)
+ }
+
var data interface{}
switch inspectType {
case inspectTypeContainer: