diff --git a/scripts/check-gray-ready.sh b/scripts/check-gray-ready.sh index b999869..3ebb344 100755 --- a/scripts/check-gray-ready.sh +++ b/scripts/check-gray-ready.sh @@ -99,6 +99,7 @@ echo "candidate_git_head=${git_head}" echo "candidate_memind_head=${memind_head}" echo "candidate_image_make_release=${image_make_release_id}" +set +e remote_result="$(ssh -o BatchMode=yes -o ConnectTimeout=15 "${HOST}" \ "GRAY_WEB_PORT='${GRAY_WEB_PORT}' GRAY_API_PORT='${GRAY_API_PORT}' IMAGE_MAKE_RELEASE_ID='${image_make_release_id}' REQUIRE_IMAGE_INTEGRATION='${REQUIRE_IMAGE_INTEGRATION}' /bin/bash" <<'REMOTE' set -euo pipefail @@ -154,6 +155,12 @@ if [[ "${REQUIRE_IMAGE_INTEGRATION}" == "1" ]]; then fi REMOTE )" +remote_status=$? +set -e printf '%s\n' "${remote_result}" +if [[ "${remote_status}" -ne 0 ]]; then + echo "gray_preflight=failed" >&2 + exit "${remote_status}" +fi echo "gray_preflight=passed"