From 82c77880673f9ca65a45d9bd98b067a0e0c127d3 Mon Sep 17 00:00:00 2001 From: Starbeamrainbowlabs Date: Thu, 14 Jan 2021 21:15:40 +0000 Subject: [PATCH] paperless-ng: check exit status of docker build --- images/paperless-ng/paperless-ng.sh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/images/paperless-ng/paperless-ng.sh b/images/paperless-ng/paperless-ng.sh index c46af68..2131fc1 100755 --- a/images/paperless-ng/paperless-ng.sh +++ b/images/paperless-ng/paperless-ng.sh @@ -9,7 +9,7 @@ output_dir="${1}"; log_msg() { # echo "[github-get-releases] [${SECONDS}] $*" >&2; - echo "[docker-images/paperless-ng] $*" >&2; + echo -e "[docker-images/paperless-ng] $*" >&2; } if [[ -z "${output_dir}" ]]; then @@ -75,6 +75,9 @@ docker_tag="${IMAGEBUILDER_REGISTRY}/paperless-ng"; log_msg "Building docker image"; docker build --no-cache --pull --tag "${docker_tag}" .; +if [[ "$?" -ne 0 ]]; then + log_msg "Error: docker build returned exit status $?"; +fi log_msg "Pushing docker image"; docker push "${docker_tag}";