2018-03-20 17:41:19 +08:00
# buildah-inspect "1" "May 2017" "buildah"
2017-05-19 00:17:35 +08:00
## NAME
2021-01-07 20:26:31 +08:00
buildah\-inspect - Display information about working containers or images or manifest lists.
2017-05-19 00:17:35 +08:00
## SYNOPSIS
2018-06-30 03:39:36 +08:00
**buildah inspect** [*options*] [**--**] *object*
2017-05-19 00:17:35 +08:00
## DESCRIPTION
2021-01-07 20:26:31 +08:00
Prints the low-level information on Buildah object(s) (e.g. container, images, manifest lists) identified by name or ID. By default, this will render all results in a
JSON array. If the container, image, or manifest lists have the same name, this will return container JSON for an unspecified type. If a format is specified,
2017-06-07 19:48:10 +08:00
the given template will be executed for each result.
2017-05-19 00:17:35 +08:00
## OPTIONS
New CI check: xref --help vs man pages
Run 'buildah --help', recursively against all subcommands,
then cross-reference the results against docs/buildah*.md.
Report differences in subcommands and/or flags.
The majority of the changes in this PR are trivial (see
below) but a handful may be controversial and require
careful review:
* Making 'bud' the default output of 'buildah help',
with 'build-using-dockerfile' as an alias. This is
the inverse of the situation until now: buildah
would list build-using-dockerfile as the primary
name. The man page, OTOH, lists 'bud'. The source
file name is 'bud'. I suspect that most people
type 'bud'. So, for consistency, I choose to make
'bud' the default visible command.
* add --encryption-key and --encrypt-layer documentation
to buildah-commit.md, and --encrypt-layer to -push.md.
Please double-check the wording here.
* remove --notruncate from buildah-images.md. The option
does not exist (although there is a TODO comment in
the code). If it should exist, it is left to the
reader to implement. I would humbly suggest that this
is a good idea, for consistency with buildah containers.
* remove --shm-size from buildah-pull.md. The option
does not exist, and I suspect this was a copy-paste error.
* remove --security-opt from run.go. It was unimplemented
and undocumented.
* remove --userns-[gu]id-map from buildah-bud.md. These
are global options, not bud options, and are documented
well enough in buildah.bud.
Trivial (IMO) changes:
* split options in man pages, from '**--foo, -f**'
to '**--foo**, **-f**'. This conforms with the style
used in podman man pages.
* add missing one-letter aliases (usually "-q", "-a")
* add missing man page entries for some easy options
* sort out-of-order subcommand listings in man pages
Finally, do note that this is a copy-and-alter duplicate of the
original script in podman, and that is horrible. In an ideal
world I would've been able to refactor the podman version into
something usable on both repos (and then more). It turns out the
differences in man page format and in special-case handling are
too broad to let me do a clean refactor.
Signed-off-by: Ed Santiago <santiago@redhat.com>
2020-09-21 22:51:19 +08:00
**--format**, ** -f** *template*
2017-05-19 00:17:35 +08:00
Use *template* as a Go template when formatting the output.
Users of this option should be familiar with the [*text/template*
package](https://golang.org/pkg/text/template/) in the Go standard library, and
2017-10-26 02:28:51 +08:00
of internals of Buildah's implementation.
2017-05-19 00:17:35 +08:00
2021-01-07 20:26:31 +08:00
**--type**, ** -t** **container** | **image** | **manifest**
2017-05-19 00:17:35 +08:00
2021-01-07 20:26:31 +08:00
Specify whether *object* is a container, image or a manifest list.
2017-05-19 00:17:35 +08:00
## EXAMPLE
buildah inspect containerID
2017-06-07 19:48:10 +08:00
2017-05-19 00:17:35 +08:00
buildah inspect --type container containerID
2017-06-07 19:48:10 +08:00
2017-05-19 00:17:35 +08:00
buildah inspect --type image imageID
2018-06-25 22:53:09 +08:00
buildah inspect --format '{{.OCIv1.Config.Env}}' alpine
2017-05-19 00:17:35 +08:00
## SEE ALSO
buildah(1)