diff --git a/build/root/install.sh b/build/root/install.sh index 476f43d..e55bc6d 100644 --- a/build/root/install.sh +++ b/build/root/install.sh @@ -3,9 +3,22 @@ # exit script if return code != 0 set -e -# release tag name from build arg, stripped of build ver using string manipulation +# release tag name from buildx arg, stripped of build ver using string manipulation RELEASETAG="${1//-[0-9][0-9]/}" +# target arch from buildx arg +TARGETARCH="${2}" + +if [[ -z "${RELEASETAG}" ]]; then + echo "[warn] Release tag name from build arg is empty, exiting script..." + exit 1 +fi + +if [[ -z "${TARGETARCH}" ]]; then + echo "[warn] Target architecture name from build arg is empty, exiting script..." + exit 1 +fi + # note do NOT download build scripts - inherited from int script with envvars common defined # get target arch from Dockerfile argument