diff --git a/obs-packaging/build_all.sh b/obs-packaging/build_all.sh index 9d7acbb7a4..97218e31b8 100755 --- a/obs-packaging/build_all.sh +++ b/obs-packaging/build_all.sh @@ -4,7 +4,12 @@ # # SPDX-License-Identifier: Apache-2.0 # -set -e +[ -z "${DEBUG}" ] || set -o xtrace + +set -o errexit +set -o nounset +set -o pipefail + script_dir=$(dirname "$0") #Note:Lets update qemu and the kernel first, they take longer to build. diff --git a/obs-packaging/build_from_docker.sh b/obs-packaging/build_from_docker.sh index 063384816b..2f35818c49 100755 --- a/obs-packaging/build_from_docker.sh +++ b/obs-packaging/build_from_docker.sh @@ -4,9 +4,12 @@ # # SPDX-License-Identifier: Apache-2.0 # +[ -z "${DEBUG}" ] || set -o xtrace + +set -o errexit +set -o nounset +set -o pipefail -set -x -set -e script_dir=$( cd $( dirname "${BASH_SOURCE[0]}" ) && pwd ) cache_dir=${PWD}/obs-cache diff --git a/obs-packaging/kata-containers-image/update.sh b/obs-packaging/kata-containers-image/update.sh index bc2bb78f6c..2d5478115c 100755 --- a/obs-packaging/kata-containers-image/update.sh +++ b/obs-packaging/kata-containers-image/update.sh @@ -11,7 +11,12 @@ # Automation script to create specs to build kata-containers-image # Default image to build is the one specified in file versions.txt # located at the root of the repository. -set -e + +[ -z "${DEBUG}" ] || set -o xtrace + +set -o errexit +set -o nounset +set -o pipefail source ../versions.txt source ../scripts/pkglib.sh diff --git a/obs-packaging/kernel/update.sh b/obs-packaging/kernel/update.sh index 1c82be14a2..02cb56e5e8 100755 --- a/obs-packaging/kernel/update.sh +++ b/obs-packaging/kernel/update.sh @@ -9,7 +9,11 @@ # ex: ts=8 sw=4 sts=4 et filetype=sh # Automation script to create specs to build Kata containers kernel -set -e +[ -z "${DEBUG}" ] || set -o xtrace + +set -o errexit +set -o nounset +set -o pipefail source ../versions.txt source ../scripts/pkglib.sh diff --git a/obs-packaging/ksm-throttler/update.sh b/obs-packaging/ksm-throttler/update.sh index 18a1d719d8..5c7618fef3 100755 --- a/obs-packaging/ksm-throttler/update.sh +++ b/obs-packaging/ksm-throttler/update.sh @@ -11,7 +11,11 @@ # Automation script to create specs to build ksm-throttler. # Default: Build is the one specified in file configure.ac # located at the root of the repository. -set -e +[ -z "${DEBUG}" ] || set -o xtrace + +set -o errexit +set -o nounset +set -o pipefail source ../versions.txt source ../scripts/pkglib.sh diff --git a/obs-packaging/proxy/update.sh b/obs-packaging/proxy/update.sh index c62fe23c82..06f35ac083 100755 --- a/obs-packaging/proxy/update.sh +++ b/obs-packaging/proxy/update.sh @@ -8,7 +8,11 @@ # ex: ts=8 sw=4 sts=4 et filetype=sh # # Automation script to create specs to build kata-proxy -set -e +[ -z "${DEBUG}" ] || set -o xtrace + +set -o errexit +set -o nounset +set -o pipefail source ../versions.txt source ../scripts/pkglib.sh diff --git a/obs-packaging/qemu-lite/update.sh b/obs-packaging/qemu-lite/update.sh index 60d348934f..bbc872e377 100755 --- a/obs-packaging/qemu-lite/update.sh +++ b/obs-packaging/qemu-lite/update.sh @@ -8,7 +8,11 @@ # ex: ts=8 sw=4 sts=4 et filetype=sh # Automation script to create specs to build kata containers kernel -set -e +[ -z "${DEBUG}" ] || set -o xtrace + +set -o errexit +set -o nounset +set -o pipefail source ../versions.txt source ../scripts/pkglib.sh diff --git a/obs-packaging/qemu-vanilla/update.sh b/obs-packaging/qemu-vanilla/update.sh index 9ef4aec108..603023e65d 100755 --- a/obs-packaging/qemu-vanilla/update.sh +++ b/obs-packaging/qemu-vanilla/update.sh @@ -9,7 +9,11 @@ # ex: ts=8 sw=4 sts=4 et filetype=sh # Automation script to create specs to build kata containers kernel -set -e +[ -z "${DEBUG}" ] || set -o xtrace + +set -o errexit +set -o nounset +set -o pipefail source ../versions.txt source ../scripts/pkglib.sh diff --git a/obs-packaging/runtime/update.sh b/obs-packaging/runtime/update.sh index 9a61971715..f770978e91 100755 --- a/obs-packaging/runtime/update.sh +++ b/obs-packaging/runtime/update.sh @@ -11,7 +11,11 @@ # Automation script to create specs to build kata-runtime # Default: Build is the one specified in file configure.ac # located at the root of the repository. -set -e +[ -z "${DEBUG}" ] || set -o xtrace + +set -o errexit +set -o nounset +set -o pipefail source ../versions.txt source ../scripts/pkglib.sh diff --git a/obs-packaging/shim/update.sh b/obs-packaging/shim/update.sh index fc83fd1607..e28ba4d52b 100755 --- a/obs-packaging/shim/update.sh +++ b/obs-packaging/shim/update.sh @@ -9,7 +9,11 @@ # ex: ts=8 sw=4 sts=4 et filetype=sh # # Automation script to create specs to build kata-shim -set -e +[ -z "${DEBUG}" ] || set -o xtrace + +set -o errexit +set -o nounset +set -o pipefail source ../versions.txt source ../scripts/pkglib.sh