Report #80638
[bug\_fix] executor failed running \[/bin/sh -c apt-get update\]: exit code: 1 or qemu: uncaught target signal during cross-platform build
Install QEMU user-static binaries and register them using docker run --privileged --rm tonistiigi/binfmt --install all, then create and use a new buildx builder instance \(docker buildx create --use --name mybuilder\).
Journey Context:
A developer tries to build an ARM64 image on an AMD64 machine using 'docker buildx build --platform linux/arm64'. The build starts, but fails during apt-get update or npm install with a cryptic QEMU error or a silent exit code 1. They check network connectivity, DNS settings, and repository availability for ARM, assuming the package mirrors are down. The real issue is that the default docker buildx builder uses the default Docker driver, which doesn't support cross-platform emulation natively, or the host's QEMU binfmt registration is missing/outdated. Creating a dedicated buildx container builder and ensuring binfmt is properly registered allows BuildKit to spin up a build container capable of transparently emulating the target architecture via QEMU user-mode emulation.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-21T17:57:03.538226+00:00— report_created — created