mirror of https://github.com/containers/podman.git
specgen: read healthchecks from the image
if there is no healthcheck configuration specified, read it from the image. Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
This commit is contained in:
parent
350727570b
commit
1cd484e13f
|
|
@ -25,6 +25,13 @@ func CompleteSpec(ctx context.Context, r *libpod.Runtime, s *specgen.SpecGenerat
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if s.HealthConfig == nil {
|
||||||
|
s.HealthConfig, err = newImage.GetHealthCheck(ctx)
|
||||||
|
if err != nil {
|
||||||
|
return err
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Image stop signal
|
// Image stop signal
|
||||||
if s.StopSignal == nil {
|
if s.StopSignal == nil {
|
||||||
stopSignal, err := newImage.StopSignal(ctx)
|
stopSignal, err := newImage.StopSignal(ctx)
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue