mirror of
https://github.com/podman-container-tools/podman.git
synced 2026-08-27 18:57:53 +00:00
test/apiv2: build healthcheck image as docker
The healthcheck inherit tests build their image with the default oci
format, which drops HEALTHCHECK. The build only warns about it and the
test sends that to /dev/null, so the image has no health config, there
is nothing to inherit and all 21 assertions come back null.
Fixes: 16a1d3fbe9 ("support healthcheck: {} inherits healthcheck from image")
Signed-off-by: Tushar Verma <tusharmyself06@gmail.com>
This commit is contained in:
parent
8efac905d6
commit
e78fdb7c3c
1 changed files with 2 additions and 1 deletions
|
|
@ -645,7 +645,8 @@ cat >$HEALTHCHECK_INHERIT_TMPD/Dockerfile <<EOF
|
|||
FROM $IMAGE
|
||||
HEALTHCHECK --interval=99s --timeout=98s --start-period=97s --start-interval=96s --retries=95 CMD true
|
||||
EOF
|
||||
podman build -t healthcheck_inherit $HEALTHCHECK_INHERIT_TMPD &>/dev/null
|
||||
# HEALTHCHECK is only recorded in the docker image format, the oci default drops it
|
||||
podman build --format docker -t healthcheck_inherit $HEALTHCHECK_INHERIT_TMPD &>/dev/null
|
||||
|
||||
# empty Test inherits the image healthcheck unchanged (all fields preserved)
|
||||
t POST containers/create Image=healthcheck_inherit Cmd='["top"]' Healthcheck='{"Test":[]}' 201 \
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue