Skip to content

Publish the docker image as a multi-arch (amd64 + arm64) manifest#746

Open
pimzand wants to merge 1 commit into
frePPLe:masterfrom
macroscoop:feat/multi-arch-image
Open

Publish the docker image as a multi-arch (amd64 + arm64) manifest#746
pimzand wants to merge 1 commit into
frePPLe:masterfrom
macroscoop:feat/multi-arch-image

Conversation

@pimzand
Copy link
Copy Markdown

@pimzand pimzand commented May 20, 2026

Closes #716.

The published ghcr.io/frepple/frepple-community image 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 build job into a dedicated docker job, built as a native matrix — amd64 on ubuntu-24.04, arm64 on ubuntu-24.04-arm — and a merge job stitches the two into one manifest list with docker buildx imagetools. Native runners avoid QEMU, so the arm64 leg compiles the C++ engine at native speed (~9 min, vs ~8 min for amd64).

  • build still runs once on amd64 (test suite, release assets) — unchanged.
  • The image name is read from the tag the cmake docker target produces, so the jobs are not edition-hardcoded.
  • Both new jobs keep the existing frePPLe/frepple guard, so the enterprise build is untouched. To extend multi-arch to the EE image, add frePPLe/frepple-enterprise-dev to the two if: guards — nothing else changes. (ubuntu-24.04-arm runners 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 a manifest.list.v2 with linux/amd64 + linux/arm64 entries, and the compiled frepple binary 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.

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>
@jdetaeye jdetaeye added this to the Current milestone May 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

How to run frepple using docker on Mac M1 series processors

2 participants