fix hooks scripts

This commit is contained in:
David Personette 2019-09-03 19:09:52 -04:00
parent df894f716b
commit b493330c7d
2 changed files with 8 additions and 8 deletions

View File

@ -7,10 +7,10 @@ BUILD_ARCH=$(echo "${DOCKERFILE_PATH}" | cut -d '.' -f2)
TAGS_API="https://api.github.com/repos/multiarch/qemu-user-static/tags" TAGS_API="https://api.github.com/repos/multiarch/qemu-user-static/tags"
URL="https://github.com/multiarch/qemu-user-static/releases/download" URL="https://github.com/multiarch/qemu-user-static/releases/download"
LATEST_TAG=$(curl -LSs $TAGS_API \ LATEST_TAG=$(curl -Ls $TAGS_API | \
| awk -F'"' '/name.*v[0-9]/ {print $4; exit}') awk -F'"' '/name.*v[0-9]/ {print $4; exit}')
STATIC_ARCH=$([ "${BUILD_ARCH}" == "armhf" ] && \ STATIC_ARCH=$([ "${BUILD_ARCH}" == "armhf" ] && \
echo "${BUILD_ARCH::-2}" || echo "${BUILD_ARCH}") echo "${BUILD_ARCH::-2}" || echo "${BUILD_ARCH}")
curl -LSs "${URL}/${LATEST_TAG}/x86_64_qemu-${STATIC_ARCH}-static.tar.gz" \ curl -Ls "${URL}/${LATEST_TAG}/x86_64_qemu-${STATIC_ARCH}-static.tar.gz" | \
| tar xzv tar xzv