mirror of
https://github.com/containers/podman.git
synced 2025-09-26 08:14:14 +08:00
support health checks from image configs
Health checks may be defined in the container config or the config of an image. So far, Podman only looked at the container config. The plumbing happened in libimage but add a regression test to Podman as well to make sure the glue code will not regress. Note that I am pinning github.com/onsi/gomega to v1.16.0 since v1.17.0 requires go 1.16 which in turn is breaking CI. Fixes: #12226 Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
This commit is contained in:
5
vendor/github.com/containers/common/libimage/inspect.go
generated
vendored
5
vendor/github.com/containers/common/libimage/inspect.go
generated
vendored
@ -187,7 +187,12 @@ func (i *Image) Inspect(ctx context.Context, options *InspectOptions) (*ImageDat
|
||||
return nil, err
|
||||
}
|
||||
data.Comment = dockerManifest.Comment
|
||||
// NOTE: Health checks may be listed in the container config or
|
||||
// the config.
|
||||
data.HealthCheck = dockerManifest.ContainerConfig.Healthcheck
|
||||
if data.HealthCheck == nil {
|
||||
data.HealthCheck = dockerManifest.Config.Healthcheck
|
||||
}
|
||||
}
|
||||
|
||||
if data.Annotations == nil {
|
||||
|
Reference in New Issue
Block a user