1
0
mirror of https://github.com/docker/cli.git synced 2025-07-30 17:03:07 +03:00
Signed-off-by: Amit Shukla <amit.shukla@docker.com>
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
This commit is contained in:
Amit Shukla
2016-06-13 19:57:19 -07:00
committed by Tibor Vass
parent bfe4e46682
commit 593ee1e29d
16 changed files with 730 additions and 8 deletions

View File

@ -10,15 +10,15 @@ parent = "smn_cli"
# inspect
Usage: docker inspect [OPTIONS] CONTAINER|IMAGE [CONTAINER|IMAGE...]
Usage: docker inspect [OPTIONS] CONTAINER|IMAGE|TASK [CONTAINER|IMAGE|TASK...]
Return low-level information on a container or image
Return low-level information on a container or image or task
-f, --format="" Format the output using the given go template
--help Print usage
--type=container|image Return JSON for specified type, permissible
values are "image" or "container"
-s, --size Display total file sizes if the type is container
-f, --format="" Format the output using the given go template
--help Print usage
--type=container|image|task Return JSON for specified type, permissible
values are "image" or "container" or "task"
-s, --size Display total file sizes if the type is container
By default, this will render all results in a JSON array. If the container and
image have the same name, this will return container JSON for unspecified type.
@ -47,6 +47,10 @@ straightforward manner.
$ docker inspect --format='{{.LogPath}}' $INSTANCE_ID
**Get a Task's image name:**
$ docker inspect --format='{{.Container.Spec.Image}}' $INSTANCE_ID
**List All Port Bindings:**
One can loop over arrays and maps in the results to produce simple text