Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Multi-platform builds are not visible in the local Docker image registry #2707

Open
asreich opened this issue Sep 19, 2024 · 3 comments
Open
Labels
kind/enhancement New feature or request status/triage

Comments

@asreich
Copy link

asreich commented Sep 19, 2024

Description

Problem: When running docker buildx build targeting multiple architectures the resulting images cannot be viewed in docker image ls. This works if you only target ONE platform per docker buildx build command, but not multiple.

I've read all of #166 and I understand the initial question was resolved but I haven't been able to find a followup issue for the related problem listed above. I have looked through the buildx CLI and have been unable to find a similar command to docker image ls that lists images instead of the buildx drivers listed by docker buildx ls.

Are there plans to enable this support in an upcoming release?

@asreich asreich added kind/enhancement New feature or request status/triage labels Sep 19, 2024
@tonistiigi
Copy link
Member

@thaJeztah Transfer to moby? (Afaik this works with containerd store).

@thompson-shaun thompson-shaun added kind/bug Something isn't working kind/enhancement New feature or request and removed kind/enhancement New feature or request kind/bug Something isn't working labels Oct 8, 2024
@toby-griffiths
Copy link

Pardon my ignorance if I've got this wrong, but I thought you had to use --load to have then appear at all in the local images list?

@thaJeztah
Copy link
Member

The --load option is needed if you are using a custom builder; e.g. if you created a builder using docker buildx create a separate instance of the BuildKit daemon is created that's running inside a container. In that case the BuildKit builder runs isolated from the Docker Engine and doesn't share the image store. When running a docker buildx build with that builder, result of the build only remains in the builder's cache, unless you either --push the result or --load the result into the Docker Engine.

If you use the default builder (the BuildKit instance that's compiled into the Docker Engine itself), it's not needed to --load the image, because BuildKit in that case shares the image store with the Docker Engine. However for multi-platform builds, you need to have the containerd image store enabled to allow the Docker Engine's image store to preserve multi-platform images (without the containerd image store, it can only store a single platform per image);

With the containerd image store enabled, you don't need a custom builder for building multi-platform images (so you can use docker builder use default to use the built-in version of BuildKit)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/enhancement New feature or request status/triage
Projects
None yet
Development

No branches or pull requests

5 participants