Publish the docker image as a multi-arch (amd64 + arm64) manifest#746
Open
pimzand wants to merge 1 commit into
Open
Publish the docker image as a multi-arch (amd64 + arm64) manifest#746pimzand wants to merge 1 commit into
pimzand wants to merge 1 commit into
Conversation
Build the runtime image natively on each architecture in a matrix job -- amd64 on ubuntu-24.04, arm64 on ubuntu-24.04-arm -- and stitch the two into one manifest list with docker buildx imagetools. Native runners avoid QEMU emulation, so the arm64 build is as fast as amd64. The docker build and push move out of the build job into a dedicated docker job (plus a merge job); the test suite still runs once on amd64. The image name is read from the tag the cmake docker target produces, so the jobs are edition-agnostic. They keep the existing frePPLe/frepple-only guard, leaving the enterprise build untouched. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #716.
The published
ghcr.io/frepple/frepple-communityimage is currently linux/amd64 only. This publishes it as a multi-arch amd64 + arm64 manifest, so frePPLe runs natively on arm64 hosts (AWS Graviton, Ampere, Apple Silicon) without QEMU emulation.Approach
The docker build and push move out of the
buildjob into a dedicateddockerjob, built as a native matrix — amd64 onubuntu-24.04, arm64 onubuntu-24.04-arm— and amergejob stitches the two into one manifest list withdocker buildx imagetools. Native runners avoid QEMU, so the arm64 leg compiles the C++ engine at native speed (~9 min, vs ~8 min for amd64).buildstill runs once on amd64 (test suite, release assets) — unchanged.dockertarget produces, so the jobs are not edition-hardcoded.frePPLe/freppleguard, so the enterprise build is untouched. To extend multi-arch to the EE image, addfrePPLe/frepple-enterprise-devto the twoif:guards — nothing else changes. (ubuntu-24.04-armrunners are free for public repos but billed on private ones.)Validation
Dry-run on a fork with the guards and image namespace retargeted: https://github.com/macroscoop/frepple/actions/runs/26171366257 — all four jobs green. The resulting
:<version>is amanifest.list.v2withlinux/amd64+linux/arm64entries, and the compiledfrepplebinary inside each image is the correct native ELF.Per-architecture images are pushed as
:<version>-<arch>tags and then merged; those interim tags remain in the registry — happy to add a prune step or switch to push-by-digest if you prefer.