diff options
author | Chris Evich <cevich@redhat.com> | 2018-10-15 09:48:19 -0400 |
---|---|---|
committer | Chris Evich <cevich@redhat.com> | 2018-10-15 09:48:19 -0400 |
commit | b610913ef55ac36d0b145a7d20461649650cc5a1 (patch) | |
tree | f3a82b57e462d313381ff2ab86b462faac37f158 /contrib/python/podman | |
parent | 3639ac1ad009ad9579e27cb15ff9095c5c92eb76 (diff) | |
download | podman-b610913ef55ac36d0b145a7d20461649650cc5a1.tar.gz podman-b610913ef55ac36d0b145a7d20461649650cc5a1.tar.bz2 podman-b610913ef55ac36d0b145a7d20461649650cc5a1.zip |
Cirrus: Enable debugging delay on non-zero exit
There have been some python-podman flakes observed across multiple CI
systems. Support capturing a VM for further investigation in the
event of a non-zero exit. This is done by printing a warning message
and delaying script-exit for a long time. Hopefully a human will notice
and have an opportunity to enable deletion-protection on the VM.
Signed-off-by: Chris Evich <cevich@redhat.com>
Diffstat (limited to 'contrib/python/podman')
-rwxr-xr-x | contrib/python/podman/test/test_runner.sh | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/contrib/python/podman/test/test_runner.sh b/contrib/python/podman/test/test_runner.sh index 65cbd1e9c..081b90779 100755 --- a/contrib/python/podman/test/test_runner.sh +++ b/contrib/python/podman/test/test_runner.sh @@ -143,6 +143,18 @@ else RETURNCODE=$? fi +if [[ "$RETURNCODE" -ne 0 ]] && [[ -n "$FLAKE_DEBUG_DELAY" ]] +then + cat << EOF > /dev/stderr +***** +***** WARNING: \$FLAKE_DEBUG_DELAY IS SET AND PYTHON-PODMAN TESTS EXITED: $RETURNCODE +***** WARNING: Sleeping for 30 minutes for test-VM preservation oportunity. +***** +EOF + sleep 30m +fi + + pkill -9 podman pkill -9 conmon |