From 5363f234e1786443c622b81c631f971ffb407546 Mon Sep 17 00:00:00 2001 From: Arjo Chakravarty Date: Thu, 4 Nov 2021 08:39:36 +0800 Subject: [PATCH] [QOL improvement] Exit if the docker image does not build (#60) This PR adds a `set -e` command to make sure the script exits if the source fails to build for some reason. The previous behaviour was annoying as it would execute the last good image, however this leads to a lot of confusion when debugging. Signed-off-by: Arjo Chakravarty --- docker/debug_integration.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/docker/debug_integration.sh b/docker/debug_integration.sh index 4caeb59f..88c617be 100755 --- a/docker/debug_integration.sh +++ b/docker/debug_integration.sh @@ -57,6 +57,10 @@ fi DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )" cd $DIR + +# exit if the docker image doesn't build +set -e + # Build the docker image docker build -t mbari_lrauv_debug -f $DIR/debug_integration/Dockerfile ..