mirror of
https://github.com/containers/podman.git
synced 2025-07-18 10:08:07 +08:00
vendor: update containers/{common,storage,image,buildah}
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
This commit is contained in:
18
vendor/github.com/containers/common/libimage/inspect.go
generated
vendored
18
vendor/github.com/containers/common/libimage/inspect.go
generated
vendored
@ -180,22 +180,26 @@ func (i *Image) Inspect(ctx context.Context, options *InspectOptions) (*ImageDat
|
||||
}
|
||||
|
||||
// Docker image
|
||||
case manifest.DockerV2Schema1MediaType, manifest.DockerV2Schema2MediaType:
|
||||
case manifest.DockerV2Schema2MediaType:
|
||||
rawConfig, err := i.rawConfigBlob(ctx)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
var dockerManifest manifest.Schema2V1Image
|
||||
if err := json.Unmarshal(rawConfig, &dockerManifest); err != nil {
|
||||
var dockerConfig manifest.Schema2V1Image
|
||||
if err := json.Unmarshal(rawConfig, &dockerConfig); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
data.Comment = dockerManifest.Comment
|
||||
data.Comment = dockerConfig.Comment
|
||||
// NOTE: Health checks may be listed in the container config or
|
||||
// the config.
|
||||
data.HealthCheck = dockerManifest.ContainerConfig.Healthcheck
|
||||
if data.HealthCheck == nil && dockerManifest.Config != nil {
|
||||
data.HealthCheck = dockerManifest.Config.Healthcheck
|
||||
data.HealthCheck = dockerConfig.ContainerConfig.Healthcheck
|
||||
if data.HealthCheck == nil && dockerConfig.Config != nil {
|
||||
data.HealthCheck = dockerConfig.Config.Healthcheck
|
||||
}
|
||||
|
||||
case manifest.DockerV2Schema1MediaType, manifest.DockerV2Schema1SignedMediaType:
|
||||
// There seem to be at least _some_ images with .Healthcheck set in schema1 (possibly just as an artifact
|
||||
// of testing format conversion?), so this could plausibly read these values.
|
||||
}
|
||||
|
||||
if data.Annotations == nil {
|
||||
|
Reference in New Issue
Block a user