From 20a3e8edb8d034ddc45e32948c965bb3fe039786 Mon Sep 17 00:00:00 2001 From: strandedturtle Date: Tue, 23 Jun 2026 11:53:12 +0000 Subject: [PATCH] ci: fix release workflow producing no tags on push to main The edge tag was gated on {{is_default_branch}}, but this repo's default branch isn't main, so pushes to main generated zero tags and buildx failed with "tag is needed when pushing to registry". Gate edge on an explicit github.ref == refs/heads/main check (and latest on tag pushes), and set flavor: latest=false so the only `latest` is our explicit one. Co-Authored-By: Claude Opus 4.8 Claude-Session: https://claude.ai/code/session_013Lj6nYJQDtLaZFvvEQJGM4 --- .github/workflows/release.yml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index e934f15..80a71a1 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -25,10 +25,14 @@ jobs: uses: docker/metadata-action@v5 with: images: ${{ steps.img.outputs.name }} + flavor: latest=false + # Use explicit ref checks rather than {{is_default_branch}} — the + # repo's default branch isn't necessarily `main`, which would leave + # a push to main with zero tags (and buildx refuses to push then). tags: | type=semver,pattern={{version}} type=semver,pattern={{major}}.{{minor}} - type=raw,value=edge,enable={{is_default_branch}} + type=raw,value=edge,enable=${{ github.ref == 'refs/heads/main' }} type=raw,value=latest,enable=${{ startsWith(github.ref, 'refs/tags/v') }} - uses: docker/setup-qemu-action@v3