Docker multi-platform build using buildx
Posted on 01 Feb, 2024
Build for different platforms
Tip: To figure which platforms to build for, head over to dockerhub and find what architectures your base image supports. For example, the alpine image supports
linux/amd64
,linux/arm64
etc.
Builds generated using buildx will not be available in the local docker registry. To push the image to the registry, use the
--push
flag.To load the image into the local docker registry, use the
--load
flag.After load you can choose to export it to a tar file using
docker save <image:tag> > test.tar
and test it on another machine usingdocker load < test.tar
.
Last updated