buildx: failed to load LLB: runtime execution on platform linux/arm64 not supported
We started using the new docker buildx to build arm64 images. But it is not working with debian base image.
DOCKER_CLI_EXPERIMENTAL=enabled docker buildx build --platform linux/arm64 --load --pull -t kubedb/operator:v0.13.0-rc.0-dbg_linux_arm64 -f bin/.dockerfile .
container: kubedb/operator:v0.13.0-rc.0-dbg_linux_arm64
[+] Building 1.9s (3/3) FINISHED
=> [internal] load build definition from .dockerfile-DBG-linux_arm64 0.5s
=> => transferring dockerfile: 652B 0.0s
=> [internal] load .dockerignore 0.3s
=> => transferring context: 2B 0.0s
=> [internal] load metadata for docker.io/library/debian:stretch 1.2s
failed to solve: rpc error: code = Unknown desc = failed to solve with frontend dockerfile.v0: failed to load LLB: runtime execution on platform linux/arm64 not supported
Makefile:205: recipe for target 'bin/.container-kubedb_operator-v0.13.0-rc.0_linux_arm64-DBG' failed
make[2]: *** [bin/.container-kubedb_operator-v0.13.0-rc.0_linux_arm64-DBG] Error 1
Makefile:105: recipe for target 'push-linux_arm64' failed
make[1]: *** [push-linux_arm64] Error 2
Makefile:307: recipe for target 'release' failed
make: *** [release] Error 2
Here is the docker file:
FROM debian:stretch
ENV DEBIAN_FRONTEND noninteractive
ENV DEBCONF_NONINTERACTIVE_SEEN true
RUN set -x \
&& apt-get update \
&& apt-get install -y --no-install-recommends apt-transport-https ca-certificates tzdata locales openssl \
&& rm -rf /var/lib/apt/lists/* /usr/share/doc /usr/share/man /tmp/* \
&& localedef -i en_US -c -f UTF-8 -A /usr/share/locale/locale.alias en_US.UTF-8 \
&& echo 'Etc/UTC' > /etc/timezone && dpkg-reconfigure tzdata
ENV TZ :/etc/localtime
ENV LANG en_US.utf8
ENV LC_ALL en_US.UTF-8
ADD bin/linux_arm64/operator /operator
ENTRYPOINT ["/operator"]
I am getting anything with google search for failed to solve with frontend dockerfile.v0: failed to load LLB: runtime execution on platform linux/arm64 not supported.
On the same machine, the following arm64 image is building ok.
FROM gcr.io/distroless/base
ADD bin/linux_arm64/operator /operator
# This would be nicer as `nobody:nobody` but distroless has no such entries.
USER 65535:65535
ENTRYPOINT ["/operator"]
Any help is appreciated.
About this issue
- Original URL
- State: closed
- Created 5 years ago
- Comments: 24 (2 by maintainers)
Commits related to this issue
- Use docker to install QEmu As suggested by someone on the QEmu-user-static Github page: https://github.com/docker/buildx/issues/138#issuecomment-573202600 — committed to HeroCC/MOOSDocker by HeroCC 4 years ago
- fix builds with new builder https://github.com/docker/buildx/issues/138 Signed-off-by: Sandor Szücs <sandor.szuecs@zalando.de> — committed to zalando/skipper by szuecs 4 years ago
I had a mybuilder that was not working.
I rm-rf the old builder and then created a new one and things are working now.
So, the problem was the old builder did not have arm64. I don’t know why. Thanks @Carlosedp helping me get this working.
For me running
docker run --rm --privileged docker/binfmt:66f9012c56a8316f9244ffd7622d7c21c1f6f28dsolved the problem.
you need to install qemu-user https://github.com/docker/buildx/issues/132#issuecomment-521759117
@HeroCC: try
docker run --rm --privileged multiarch/qemu-user-static --reset -p yesinstead and it should workNote that
docker buildx lswill not listlinux/arm/v7as platform but it works.I found that on my work image, I have to constantly re-run the multiarch/qemu-user-static process after each boot. It’s a simple enough workaround for us anyway.
Delete the old builder and create a new builder.
On Fri, Aug 30, 2019, 5:50 PM Evandro Nascimento notifications@github.com wrote:
Thanks it’s works for me on azure pipelines:
It worked for me after installing qemu-user and running the getting started tutorial at multiarch/qemu-user-static
You need to restart or recreate the builder for it to pick up new qemu support.
Sorry to bug anyone, but I’m having the same issue. I’ve been trying to get this to work for a while now but can’t seem to do it. I run the following, and yet my buildx builder doesn’t have the new platforms supported, and the build gets that same error. The base image I’m trying to build is ubuntu:18.04 and I’m running on GitlabCI shared infrastructure (docker:stable image, dind service running, privileged containers enabled).
Full Build Logs: https://gitlab.com/moos-ivp/moosdocker/-/jobs/396347211 CI Configuration / scripts: https://gitlab.com/moos-ivp/moosdocker/blob/d8bc10615ddf928c8fda8cf250cfa2c973734e29/.gitlab-ci.yml
Thank you!
Thanks @tonistiigi . It seems that I had already installed it but still getting this error.