NAME¶
Podman-图像-检查-显示图像的配置
SYNOPSIS¶
podman image inspect [options] image [image ...]
DESCRIPTION¶
这会显示由名称或ID标识的图像的底层信息。默认情况下,这会将所有结果呈现在一个JSON数组中。如果指定了格式,则为每个结果执行给定的模板。
OPTIONS¶
--format , -f = 格式化¶
使用给定的GO模板格式化输出。返回的JSON的键可以用作--格式标志的值(参见下面的示例)。
下面列出了GO模板的有效占位符:
Placeholder |
Description |
---|---|
.注释... |
包括在图像中的注释信息 |
.建筑 |
映像中的软件体系结构 |
.作者 |
图像作者 |
.评论 |
形象评论 |
.配置... |
具有配置信息的结构 |
.创建.. |
镜像创建时间(字符串,ISO3601) |
.摘要 |
图像摘要(sha256:+64字符哈希) |
图形驱动程序..。 |
图形驱动程序信息的结构 |
.健康检查... |
运行状况检查信息的结构 |
.历史 |
存储在图像中的历史信息 |
.id |
镜像ID(完整64个字符的哈希) |
.Labels..。 |
图像中包含的标签信息 |
.ManifestType |
图像的清单类型 |
.名称历史记录 |
存储在图像中的姓名历史信息 |
.OS |
镜像中软件的操作系统 |
.父母 |
指定映像的父映像 |
.RepoDigest |
图像的存储库摘要 |
.RepoTag |
映像的存储库标签 |
.RootFS... |
根文件系统信息的结构 |
.Size |
图像大小,以字节为单位 |
.用户 |
以默认用户身份执行图像 |
.版本 |
图像版本 |
.虚拟大小 |
图像的虚拟大小,以字节为单位 |
EXAMPLE¶
检查有关指定映像的信息:
$ podman image inspect fedora
[
{
"Id": "37e5619f4a8ca9dbc4d6c0ae7890625674a10dbcfb76201399e2aaddb40da17d",
"Digest": "sha256:1b0d4ddd99b1a8c8a80e885aafe6034c95f266da44ead992aab388e6aa91611a",
"RepoTags": [
"registry.fedoraproject.org/fedora:latest"
],
"RepoDigests": [
"registry.fedoraproject.org/fedora@sha256:1b0d4ddd99b1a8c8a80e885aafe6034c95f266da44ead992aab388e6aa91611a",
"registry.fedoraproject.org/fedora@sha256:b5290db40008aae9272ad3a6bd8070ef7ecd547c3bef014b894c327960acc582"
],
"Parent": "",
"Comment": "Created by Image Factory",
"Created": "2021-08-09T05:48:47Z",
"Config": {
"Env": [
"DISTTAG=f34container",
"FGC=f34",
"container=oci"
],
"Cmd": [
"/bin/bash"
],
"Labels": {
"license": "MIT",
"name": "fedora",
"vendor": "Fedora Project",
"version": "34"
}
},
"Version": "1.10.1",
"Author": "",
"Architecture": "amd64",
"Os": "linux",
"Size": 183852302,
"VirtualSize": 183852302,
"GraphDriver": {
"Name": "overlay",
"Data": {
"UpperDir": "/home/dwalsh/.local/share/containers/storage/overlay/0203e243f1ca4b6bb49371ecd21363212467ec6d7d3fa9f324cd4e78cc6b5fa2/diff",
"WorkDir": "/home/dwalsh/.local/share/containers/storage/overlay/0203e243f1ca4b6bb49371ecd21363212467ec6d7d3fa9f324cd4e78cc6b5fa2/work"
}
},
"RootFS": {
"Type": "layers",
"Layers": [
"sha256:0203e243f1ca4b6bb49371ecd21363212467ec6d7d3fa9f324cd4e78cc6b5fa2"
]
},
"Labels": {
"license": "MIT",
"name": "fedora",
"vendor": "Fedora Project",
"version": "34"
},
"Annotations": {},
"ManifestType": "application/vnd.docker.distribution.manifest.v2+json",
"User": "",
"History": [
{
"created": "2021-08-09T05:48:47Z",
"comment": "Created by Image Factory"
}
],
"NamesHistory": [
"registry.fedoraproject.org/fedora:latest"
]
}
]
检查指定映像的映像ID:
$ podman image inspect --format '{{ .Id }}' fedora
37e5619f4a8ca9dbc4d6c0ae7890625674a10dbcfb76201399e2aaddb40da17d
另请参阅¶
[podman(1)] , [podman-image(1)] , [podman-inspect(1)]
HISTORY¶
2021年9月,最初由Dan Walshdwalsh@redhat.com编译