#4574: - Fix Docker arm64 image crash (`exec format error`) caused by tag race condition
Cluster:
Docker Enhancements and Fixes
Fixes #4566
## Problem
Both `build-amd64` and `build-arm64` jobs were tagging their images with *all* architecture suffixes. This caused a race condition where whichever job finished last would overwrite the other's tags—so `main-arm64` ended up pointing to an amd64 image.
## Solution
Each architecture build job now only tags with its own suffix:
- `build-amd64` → `main-amd64`, `v*-amd64`
- `build-arm64` → `main-arm64`, `v*-arm64`
The `create-manifest` job continues to create the multi-arch manifest (`main`, `v*`) by combining both digests.
## Test plan
- [ ] Verify workflow runs successfully on push to main
- [ ] Confirm `main-arm64` image runs on arm64 host without exec format error
- [ ] Confirm `main-amd64` image runs on amd64 host
- [ ] Confirm `main` manifest auto-selects correct architecture
<!-- greptile_comment -->
<h2>Greptile Overview</h2>
<h3>Greptile Summary</h3>
This PR updates `.github/workflows/docker-release.yml` to prevent cross-architecture tag overwrites when building/pushing Docker images to GHCR. The amd64 and arm64 build jobs now only publish architecture-suffixed tags (e.g., `main-amd64`, `vX.Y.Z-amd64` and `main-arm64`, `vX.Y.Z-arm64`), while the `create-manifest` job continues to publish the unsuffixed tags (`main`, `vX.Y.Z`) as a multi-arch manifest composed from the two build digests.
This fits the existing release workflow by keeping per-arch images available under explicit tags, and reserving the generic tags for the final manifest list so consumers pulling `:main` or `:v*` get the correct architecture automatically.
<h3>Confidence Score: 4/5</h3>
- This PR is safe to merge and directly addresses the cross-arch tag overwrite issue with minimal workflow changes.
- Changes are narrowly scoped to tag generation in the release workflow and align with the intended model: arch-specific tags per build, generic tags only on the manifest list. The main residual risk is operational (manifest job failure would leave only suffixed tags), not a functional regression in the workflow itself.
- No files require special attention
<!-- greptile_other_comments_section -->
<sub>(3/5) Reply to the agent's comments like "Can you suggest a fix for this @greptileai?" or ask follow-up questions!</sub>
**Context used:**
- Context from `dashboard` - CLAUDE.md ([source](https://app.greptile.com/review/custom-context?memory=fd949e91-5c3a-4ab5-90a1-cbe184fd6ce8))
- Context from `dashboard` - AGENTS.md ([source](https://app.greptile.com/review/custom-context?memory=0d0c8278-ef8e-4d6c-ab21-f5527e322f13))
<!-- /greptile_comment -->
Most Similar PRs
#12033: feat(docker): add linux/riscv64 image to Docker release
by gounthar · 2026-02-08
79.8%
#4450: fix bug #4366: Error: Config validation failed: plugins.slots.memor...
by tryagain3 · 2026-01-30
78.3%
#4695: Fixed the default CLI image to use published GHCR image
by TASMAYU · 2026-01-30
78.0%
#4238: Fix/docker migration atomicity
by ricardotrevisan · 2026-01-29
77.2%
#2609: bugfix: Docker build fails on main: .dockerignore excludes required...
by yanquankun · 2026-01-27
76.9%
#16707: Claude/review deployment setup wbbcc
by absurdfounder · 2026-02-15
76.3%
#22491: Use multi-stage docker build to reduce image size from 4.72GB -> 2....
by mm-zacharydavison · 2026-02-21
75.9%
#9190: feat(docker): Add autonomous container self-restart and runtime pac...
by alexdredmon · 2026-02-05
75.3%
#9102: Remove UI build for Discord-onlyUpdate Dockerfile
by nbliss16 · 2026-02-04
75.1%
#11576: Update Dockerfile, change file ownership during copy to prevent long …
by fastali · 2026-02-08
74.9%