1podman-inspect(1)           General Commands Manual          podman-inspect(1)
2
3
4

NAME

6       podman-inspect  - Display a container, image, volume, network, or pod's
7       configuration
8
9

SYNOPSIS

11       podman inspect [options] name [...]
12
13

DESCRIPTION

15       This displays the low-level information on containers and images  iden‐
16       tified  by  name  or ID. By default, this renders all results in a JSON
17       array. If the inspect type is all, the order of inspection is: contain‐
18       ers, images, volumes, network, pods.
19        If  a container has the same name as an image, then the container JSON
20       is returned, and so on.
21        If a format is specified, the given template is executed for each  re‐
22       sult.
23
24
25       For more inspection options, see also podman-container-inspect(1), pod‐
26       man-image-inspect(1), podman-network-inspect(1), podman-pod-inspect(1),
27       and podman-volume-inspect(1).
28
29

OPTIONS

31   --format, -f=format
32       Format  the  output  using  the given Go template.  The keys of the re‐
33       turned JSON can be used as the values for the --format flag (see  exam‐
34       ples below).
35
36
37   --latest, -l
38       Instead  of  providing  the  container name or ID, use the last created
39       container.  Note: the last started container can be from other users of
40       Podman on the host machine.  (This option is not available with the re‐
41       mote Podman client, including Mac  and  Windows  (excluding  WSL2)  ma‐
42       chines)
43
44
45   --size, -s
46       In  addition  to normal output, display the total file size if the type
47       is a container.
48
49
50   --type, -t=type
51       Return JSON for the specified type.  Type can be 'container',  'image',
52       'volume',  'network',  'pod',  or 'all' (default: all) (Only meaningful
53       when invoked as podman inspect)
54
55

EXAMPLE

57       # podman inspect fedora
58       [
59           {
60               "Id": "f0858ad3febdf45bb2e5501cb459affffacef081f79eaa436085c3b6d9bd46ca",
61               "Digest": "sha256:d4f7df6b691d61af6cee7328f82f1d8afdef63bc38f58516858ae3045083924a",
62               "RepoTags": [
63                   "docker.io/library/fedora:latest"
64               ],
65               "RepoDigests": [
66                   "docker.io/library/fedora@sha256:8fa60b88e2a7eac8460b9c0104b877f1aa0cea7fbc03c701b7e545dacccfb433",
67                   "docker.io/library/fedora@sha256:d4f7df6b691d61af6cee7328f82f1d8afdef63bc38f58516858ae3045083924a"
68               ],
69               "Parent": "",
70               "Comment": "",
71               "Created": "2019-10-29T03:23:37.695123423Z",
72               "Config": {
73                   "Env": [
74                       "PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin",
75                       "DISTTAG=f31-updates-candidatecontainer",
76                       "FGC=f31-updates-candidate",
77                       "FBR=f31-updates-candidate"
78                   ],
79                   "Cmd": [
80                       "/bin/bash"
81                   ],
82                   "Labels": {
83                       "maintainer": "Clement Verna \u003ccverna@fedoraproject.org\u003e"
84                   }
85               },
86               "Version": "18.06.1-ce",
87               "Author": "",
88               "Architecture": "amd64",
89               "Os": "linux",
90               "Size": 201096840,
91               "VirtualSize": 201096840,
92               "GraphDriver": {
93                   "Name": "overlay",
94                   "Data": {
95                       "UpperDir": "/home/user/.local/share/containers/storage/overlay/2ae3cee18c8ef9e0d448649747dab81c4f1ca2714a8c4550eff49574cab262c9/diff",
96                       "WorkDir": "/home/user/.local/share/containers/storage/overlay/2ae3cee18c8ef9e0d448649747dab81c4f1ca2714a8c4550eff49574cab262c9/work"
97                   }
98               },
99               "RootFS": {
100                   "Type": "layers",
101                   "Layers": [
102                       "sha256:2ae3cee18c8ef9e0d448649747dab81c4f1ca2714a8c4550eff49574cab262c9"
103                   ]
104               },
105               "Labels": {
106                   "maintainer": "Clement Verna \u003ccverna@fedoraproject.org\u003e"
107               },
108               "Annotations": {},
109               "ManifestType": "application/vnd.docker.distribution.manifest.v2+json",
110               "User": "",
111               "History": [
112                   {
113                       "created": "2019-01-16T21:21:55.569693599Z",
114                       "created_by": "/bin/sh -c #(nop)  LABEL maintainer=Clement Verna \u003ccverna@fedoraproject.org\u003e",
115                       "empty_layer": true
116                   },
117                   {
118                       "created": "2019-09-27T21:21:07.784469821Z",
119                       "created_by": "/bin/sh -c #(nop)  ENV DISTTAG=f31-updates-candidatecontainer FGC=f31-updates-candidate FBR=f31-updates-candidate",
120                       "empty_layer": true
121                   },
122                   {
123                       "created": "2019-10-29T03:23:37.355187998Z",
124                       "created_by": "/bin/sh -c #(nop) ADD file:298f828afc880ccde9205fc4418435d5e696ad165e283f0530d0b1a74326d6dc in / "
125                   },
126                   {
127                       "created": "2019-10-29T03:23:37.695123423Z",
128                       "created_by": "/bin/sh -c #(nop)  CMD [\"/bin/bash\"]",
129                       "empty_layer": true
130                   }
131               ],
132               "NamesHistory": []
133           }
134       ]
135
136
137       # podman inspect a04 --format "{{.ImageName}}"
138       fedora
139
140
141       # podman inspect a04 --format "{{.GraphDriver.Name}}"
142       overlay
143
144
145       # podman image inspect --format "size: {{.Size}}" alpine
146       size:   4405240
147
148
149       podman container inspect --latest --format {{.EffectiveCaps}}
150       [CAP_CHOWN CAP_DAC_OVERRIDE CAP_FSETID CAP_FOWNER CAP_SETGID CAP_SETUID CAP_SETFCAP CAP_SETPCAP CAP_NET_BIND_SERVICE CAP_KILL]
151
152
153       # podman inspect myPod --type pod --format "{{.Name}}"
154       myPod
155
156
157       # podman inspect myVolume --type volume --format "{{.Name}}"
158       myVolume
159
160
161       # podman inspect nyNetwork --type network --format "{{.name}}"
162       myNetwork
163
164
165

SEE ALSO

167       podman(1), podman-container-inspect(1),  podman-image-inspect(1),  pod‐
168       man-network-inspect(1), podman-pod-inspect(1), podman-volume-inspect(1)
169
170

HISTORY

172       July   2017,   Originally   compiled  by  Dan  Walsh  dwalsh@redhat.com
173       ⟨mailto:dwalsh@redhat.com⟩
174
175
176
177                                                             podman-inspect(1)
Impressum