Merge "build-docker-images: additional error handling"

This commit is contained in:
Zuul 2023-09-12 16:30:33 +00:00 committed by Gerrit Code Review
commit 7c4121a17f

View File

@ -655,6 +655,7 @@ function build_image_docker {
get_git "${DOCKER_REPO}" "${DOCKER_REF}" "${DOCKER_PATCHES}" get_git "${DOCKER_REPO}" "${DOCKER_REF}" "${DOCKER_PATCHES}"
if [ $? -ne 0 ]; then if [ $? -ne 0 ]; then
echo "Failed to clone or update ${DOCKER_REPO}. Aborting..." >&2 echo "Failed to clone or update ${DOCKER_REPO}. Aborting..." >&2
RESULTS_FAILED+=(${LABEL})
cd ${ORIGWD} cd ${ORIGWD}
return 1 return 1
fi fi
@ -775,6 +776,7 @@ function build_image_script {
get_git "${SOURCE_REPO}" "${SOURCE_REF}" "${SOURCE_PATCHES}" get_git "${SOURCE_REPO}" "${SOURCE_REF}" "${SOURCE_PATCHES}"
if [ $? -ne 0 ]; then if [ $? -ne 0 ]; then
echo "Failed to clone or update ${SOURCE_REPO}. Aborting..." >&2 echo "Failed to clone or update ${SOURCE_REPO}. Aborting..." >&2
RESULTS_FAILED+=(${LABEL})
cd ${ORIGWD} cd ${ORIGWD}
return 1 return 1
fi fi