Skip to content

ci: build the Docker images natively for amd64 and arm64#659

Merged
ddeboer merged 1 commit into
mainfrom
ci/arm64-images
Jul 25, 2026
Merged

ci: build the Docker images natively for amd64 and arm64#659
ddeboer merged 1 commit into
mainfrom
ci/arm64-images

Conversation

@ddeboer

@ddeboer ddeboer commented Jul 25, 2026

Copy link
Copy Markdown
Member

Builds the two Docker images natively for amd64 and arm64 and publishes one multi-architecture manifest per version, so Apple Silicon (and other arm64 hosts) pull a native image instead of emulating amd64.

  • Matrix build on ubuntu-latest + ubuntu-24.04-arm (free for public repos): each architecture builds and boots natively, so the docker:smoke gate now covers both. This is the deciding argument over a single QEMU cross-build, which could only ever boot-test amd64 – an arm64-only runtime failure would ship silently.
  • Each leg pushes an arch-suffixed tag (<version>-amd64 / <version>-arm64); a small publish-manifest job stitches them into the <version> and latest tags with docker buildx imagetools create. The intermediate tags remain in ghcr – harmless, occasionally useful for debugging.
  • The publish-manifest job needs no release-guard of its own: needs: build propagates the skip.
  • All image dependencies are pure JS (no native addons), so the per-architecture npm ci inside the Dockerfile needs no toolchains.

Verifiable end to end without waiting for a release: gh workflow run docker.yml -f ref=@lde/search-api-server@0.0.1 re-publishes 0.0.1 as a multi-arch manifest.

- matrix build on ubuntu-latest and ubuntu-24.04-arm: each architecture
  builds AND boots natively, so the docker:smoke gate covers both – an
  emulated arm64 build could only ever boot-test amd64
- per-architecture tags (<version>-amd64/-arm64) are stitched into one
  multi-architecture manifest with docker buildx imagetools create, so
  <version> and latest resolve natively on both
- the publish-manifest job inherits the skip from the build guard via
  needs
@ddeboer
ddeboer merged commit 70c4a6f into main Jul 25, 2026
2 checks passed
@ddeboer
ddeboer deleted the ci/arm64-images branch July 25, 2026 18:18
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.

1 participant