diff options
author | OpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com> | 2019-03-14 00:31:22 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-03-14 00:31:22 -0700 |
commit | fb5f8ebcb649cc25ee0207364ac386ada855e976 (patch) | |
tree | fd986f3fd9bc108dcc5fb605cc9480c07ebc034e /cmd/podman/image.go | |
parent | 7426d4fbbeaf5ebd3d55576add89b99cd3f3f760 (diff) | |
parent | 3de5e4a99fe441e41e1a1c9f90e8bb6e0ff1bd28 (diff) | |
download | podman-fb5f8ebcb649cc25ee0207364ac386ada855e976.tar.gz podman-fb5f8ebcb649cc25ee0207364ac386ada855e976.tar.bz2 podman-fb5f8ebcb649cc25ee0207364ac386ada855e976.zip |
Merge pull request #2624 from edsantiago/inspect_usability
Usability cleanup for 'inspect'
Diffstat (limited to 'cmd/podman/image.go')
-rw-r--r-- | cmd/podman/image.go | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/cmd/podman/image.go b/cmd/podman/image.go index 52bac6ecb..0e980d4d3 100644 --- a/cmd/podman/image.go +++ b/cmd/podman/image.go @@ -31,6 +31,19 @@ var ( Example: strings.Replace(_imagesCommand.Example, "podman images", "podman image list", -1), } + inspectSubCommand cliconfig.InspectValues + _inspectSubCommand = &cobra.Command{ + Use: strings.Replace(_inspectCommand.Use, "CONTAINER | ", "", 1), + Short: "Display the configuration of an image", + Long: `Displays the low-level information on an image identified by name or ID.`, + RunE: func(cmd *cobra.Command, args []string) error { + inspectSubCommand.InputArgs = args + inspectSubCommand.GlobalFlags = MainGlobalOpts + return inspectCmd(&inspectSubCommand) + }, + Example: `podman image inspect alpine`, + } + rmSubCommand cliconfig.RmiValues _rmSubCommand = &cobra.Command{ Use: strings.Replace(_rmiCommand.Use, "rmi", "rm", 1), @@ -52,7 +65,7 @@ var imageSubCommands = []*cobra.Command{ _imagesSubCommand, _imageExistsCommand, _importCommand, - _inspectCommand, + _inspectSubCommand, _loadCommand, _pruneImagesCommand, _pullCommand, @@ -69,6 +82,9 @@ func init() { imagesSubCommand.Command = _imagesSubCommand imagesInit(&imagesSubCommand) + inspectSubCommand.Command = _inspectSubCommand + inspectInit(&inspectSubCommand) + imageCommand.SetUsageTemplate(UsageTemplate()) imageCommand.AddCommand(imageSubCommands...) imageCommand.AddCommand(getImageSubCommands()...) |