From 32195a58ae7612ca706db944cb80c81a34c530ef Mon Sep 17 00:00:00 2001 From: Liran Rotenberg Date: Sun, 6 Aug 2023 16:59:25 +0300 Subject: [PATCH] Exit when virt-v2v cold hit an error Since we now support two flows in the virt-v2v image, it doesn't end with the actual `virt-v2v` command. In that case the pod may end with success although, it didn't. Now the script will exit with an error on the first error occurrence. Signed-off-by: Liran Rotenberg --- virt-v2v/cold/entrypoint | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/virt-v2v/cold/entrypoint b/virt-v2v/cold/entrypoint index 7ee0f3008..9fc2db8f4 100755 --- a/virt-v2v/cold/entrypoint +++ b/virt-v2v/cold/entrypoint @@ -1,5 +1,5 @@ #!/usr/bin/env bash -set -o pipefail +set -o pipefail -e shopt -s nullglob if [ -z "$V2V_source"] ; then @@ -105,4 +105,4 @@ if [ "$V2V_source" == "ova" ] ; then -i ova "$V2V_diskPath" \ "${args[@]}"\ |& /usr/local/bin/virt-v2v-monitor -fi \ No newline at end of file +fi