image util unbound variable

This commit is contained in:
Antonio Ojea 2021-03-06 12:06:05 +01:00
parent f55a4ce84f
commit 88fbd7c509

View File

@ -161,9 +161,9 @@ build() {
"${SED}" -i "s|QEMUARCH|${QEMUARCHS[$arch]}|g" Dockerfile
# Register qemu-*-static for all supported processors except the current one
echo 'Registering qemu-*-static binaries in the kernel'
local sudo
local sudo=""
if [[ $(id -u) -ne 0 ]]; then
sudo=sudo
sudo="sudo"
fi
${sudo} "${KUBE_ROOT}/third_party/multiarch/qemu-user-static/register/register.sh" --reset -p yes
curl -sSL https://github.com/multiarch/qemu-user-static/releases/download/"${QEMUVERSION}"/x86_64_qemu-"${QEMUARCHS[$arch]}"-static.tar.gz | tar -xz -C "${temp_dir}"