xci: scripts: start-new-vm: Set pipefail option 25/52525/1
authorMarkos Chandras <mchandras@suse.de>
Fri, 23 Feb 2018 13:48:33 +0000 (13:48 +0000)
committerMarkos Chandras <mchandras@suse.de>
Fri, 23 Feb 2018 13:49:47 +0000 (13:49 +0000)
In commit I75a8cb8c05957bb205e63210d6cafaf54d989f32 the 'ts' utility
was added in order to print timestamps for deployment. However, this
breaks the exit code since 'pipefail' was not set so every job was
returning 'success'.

Change-Id: Ia5f47ea96a4a5be9ed0664f5c7100accc30cde51
Signed-off-by: Markos Chandras <mchandras@suse.de>
xci/scripts/vm/start-new-vm.sh

index f3ddcc0..f4cec30 100755 (executable)
@@ -333,6 +333,7 @@ if [[ $? != 0 ]]; then
                echo "Creating a default test case to run xci-deploy.sh"
                cat > ${BASE_PATH}/run_jenkins_test.sh <<EOF
 #!/bin/bash
+set -o pipefail
 export XCI_FLAVOR=mini
 cd ~/releng-xci/xci
 ./xci-deploy.sh | ts