Publish multi-arch (amd64 + arm64) container images#135
Merged
Conversation
The Dockerfile declared ARG TARGETOS/TARGETARCH but did not pin the builder stage to BUILDPLATFORM, so requesting linux/arm64 caused BuildKit to pull the arm64 golang image and run the entire build under QEMU emulation. This pins the builder to the runner's native architecture and cross-compiles via GOARCH, which is the standard fast path for pure-Go projects. Also threads version/gitCommit/gitTreeState/buildDate through -ldflags -X so images carry build metadata, and bumps the shared publish-docker workflow to v1.13.1 to enable the platforms input (linux/amd64,linux/arm64). Unblocks Apple Silicon developers who currently cannot pull the published image without emulation. Local multi-arch buildx build completes in ~49s on an M-series laptop. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
JoseSzycho
approved these changes
May 5, 2026
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.
Summary
linux/amd64andlinux/arm64images.version/gitCommit/gitTreeState/buildDateinto the manager binary via-ldflags -Xso published images carry build metadata and log it at startup.Test plan
docker buildx imagetools inspect ghcr.io/datum-cloud/network-services-operator:<tag>shows bothlinux/amd64andlinux/arm64Co-Authored-By: Claude Opus 4.6 (1M context) noreply@anthropic.com