-
Notifications
You must be signed in to change notification settings - Fork 787
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
Support easy multi-arch build à la docker buildx #3268
Comments
Having just completed a proof-of-concept github action that replaces multi-arch builds we're using buildx for, I completely agree with your sentiments. While I don't think squeezing in kitchen-sink-tool (like buildx) into buildah or podman is a good fit, there is certainly work needed on documentation and (perhaps) short-cut options to make life easier. Especially for/if somebody were interested in developing a buildx-like-tool for buildah or podman. Besides better documentation, off-hand I'm imagining having like a |
A friendly reminder that this issue had no activity for 30 days. |
A friendly reminder that this issue had no activity for 30 days. |
@nalin has been working to improve our multi-arch support. Some buildx support has made its way into buildah already |
Fantastic! I will very likely need help making use of these for containers/automation#84 I noticed there's now a |
@rhatdan @nalind more specific question: Would you expect this to work yet (assuming QEMU is setup properly)? for arch in amd64 s390x ppc64le arm64; do
buildah bud --arch=$arch --manifest example.com/foo/bar:latest /path/to/Containerfile &
done
wait $(jobs -rp)
buildah push example.com/foo/bar:latest (I'm remembering a race where the different arch's base images would frequently name-clash on pull) |
The names of base images will still be reassigned as they get re-pulled for a given architecture, but as of 1.22 (or rather containers/common 0.42) that shouldn't break anything. The main branch expands |
Oh! So I can just do like Wow, that would actually be really, REALLY cool! |
It wouldn't be a JSON list, so the |
Gosh that will be a HUGELY useful feature, thanks! Will it do the builds in parallel? Even if not...still very useful and more reliable than me trying to do it all in bash 😕 |
The |
Dang Nalin! There simply MUST be something buildah can't do...Next you'll tell me there's a |
A friendly reminder that this issue had no activity for 30 days. |
@cevich @nalind @Romain-Geissler-1A Where are we on this Issue? Do we have enough features to close it? |
IMHO the |
A friendly reminder that this issue had no activity for 30 days. |
Multiarch isn't working for me
Dockerfile
Buildah Version
|
1.19 is from before |
@arpitjindal97 the |
Do you have qemu-user-static package installed? |
Thanks @rhatdan installing Is there any easy way to install the same on MacOS ? |
I think you can do |
@baude we might want to do this automatically in the ignition script, if we are already adding packages. |
FEATURE REQUEST
Hi,
I am right now exploring how to easily create multi-arch builds in an easy way. Docker buildx seems to implement things which make the full thing rather simplified, and by checking the current man-pages of podman/buildah, it doesn't seem as easy.
One cool feature of buildx is that --platform is not a single platform, but a list of platform. Basically this allows to run one single "docker buildx build" command and in the end have a full manifest list of all the architecture you are interested about. Apparently the way this is currently done with buildah/podman is that you have to manually run all build for each arch individually (and handle parallelism yourself), then create the manifest and append all these arch images all by yourself. The buildx alternative seems like a syntactic sugar that is appealing and it would be great if buildah would support it as well.
In addition to having a list of supported platform, the other cool thing of "docker buildx build" is that thanks to a bit of builder configuration (see for example here https://medium.com/nttlabs/buildx-multiarch-2c6c2df00ca2 the "Option 3: Remote mode" paragraph) buildx can transparently execute each builds for each arch on a docker daemon running natively on this arch. Again, all this is done in a single command with just a bit of configuration. I tried to see if anything similar (automatic choose of remote daemon/remote builders based on arch) was possible with podman/buildah, but it doesn't seem so. Is this a feature that would make sense to see landing eventually ?
Cheers,
Romain
The text was updated successfully, but these errors were encountered: