diff --git a/build/debian-base/Makefile b/build/debian-base/Makefile index 379fa491962..d9f0ac5a0cd 100755 --- a/build/debian-base/Makefile +++ b/build/debian-base/Makefile @@ -80,7 +80,7 @@ ifeq ($(ARCH),amd64) else # When cross-building, only the placeholder "CROSS_BUILD_" should be removed # Register /usr/bin/qemu-ARCH-static as the handler for non-x86 binaries in the kernel - docker run --rm --privileged multiarch/qemu-user-static:register --reset + sudo ../../third_party/multiarch/qemu-user-static/register/register.sh --reset curl -sSL https://github.com/multiarch/qemu-user-static/releases/download/$(QEMUVERSION)/x86_64_qemu-$(QEMUARCH)-static.tar.gz | tar -xz -C $(TEMP_DIR) # Ensure we don't get surprised by umask settings chmod 0755 $(TEMP_DIR)/qemu-$(QEMUARCH)-static diff --git a/build/debian-hyperkube-base/Makefile b/build/debian-hyperkube-base/Makefile index d9c0d87a00a..53d7aa35a24 100644 --- a/build/debian-hyperkube-base/Makefile +++ b/build/debian-hyperkube-base/Makefile @@ -74,7 +74,7 @@ endif ifneq ($(ARCH),amd64) # Register /usr/bin/qemu-ARCH-static as the handler for non-x86 binaries in the kernel - docker run --rm --privileged multiarch/qemu-user-static:register --reset + sudo ../../third_party/multiarch/qemu-user-static/register/register.sh --reset endif docker build --pull -t $(IMAGE)-$(ARCH):$(TAG) $(TEMP_DIR) rm -rf $(TEMP_DIR) diff --git a/build/debian-iptables/Makefile b/build/debian-iptables/Makefile index 8c793db5aac..56a55ebaf36 100644 --- a/build/debian-iptables/Makefile +++ b/build/debian-iptables/Makefile @@ -32,7 +32,7 @@ build: ifneq ($(ARCH),amd64) # Register /usr/bin/qemu-ARCH-static as the handler for non-x86 binaries in the kernel - docker run --rm --privileged multiarch/qemu-user-static:register --reset + sudo ../../third_party/multiarch/qemu-user-static/register/register.sh --reset endif docker build --pull -t $(IMAGE)-$(ARCH):$(TAG) $(TEMP_DIR) diff --git a/test/images/image-util.sh b/test/images/image-util.sh index dcfd361963f..555fd821c17 100755 --- a/test/images/image-util.sh +++ b/test/images/image-util.sh @@ -83,7 +83,8 @@ build() { else ${SED} -i "s|QEMUARCH|${QEMUARCHS[$arch]}|g" Dockerfile # Register qemu-*-static for all supported processors except the current one - docker run --rm --privileged multiarch/qemu-user-static:register --reset + echo "Registering qemu-*-static binaries in the kernel" + sudo "${KUBE_ROOT}/third_party/multiarch/qemu-user-static/register/register.sh" --reset 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} # Ensure we don't get surprised by umask settings chmod 0755 "${temp_dir}/qemu-${QEMUARCHS[$arch]}-static"