From 41eb18cc702686a3bcb95e5788a71147580bc275 Mon Sep 17 00:00:00 2001 From: Lukas Greve Date: Wed, 23 Sep 2026 13:42:39 +0200 Subject: [PATCH] ci: build images only on release tags, not on every push to main A full build of both editions takes ~25 min on the fedora:host runner (run 237: 10:46-11:10), too costly to repeat on every push to main. build-image.yaml now triggers only on v*.*.* tags; the tag path already publishes the image and kickstart as a release, so the main-only upload-artifact step is dropped. Recipes are still linted and validated on every push by ci.yml. Co-Authored-By: Claude Opus 5.5 --- .gitea/workflows/build-image.yaml | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) diff --git a/.gitea/workflows/build-image.yaml b/.gitea/workflows/build-image.yaml index 760304f..314cf75 100644 --- a/.gitea/workflows/build-image.yaml +++ b/.gitea/workflows/build-image.yaml @@ -1,8 +1,10 @@ name: build-image +# Only a release tag builds images: a full build takes ~25 min on the runner, +# too costly to repeat on every push to main. Recipes are still linted and +# validated on every push by ci.yml. on: push: - branches: [main] tags: ["v*.*.*"] # Builds raw disk images of the two default-tier editions (see @@ -85,16 +87,6 @@ jobs: ./build-image.sh --dish "$dish" --root-size ${{ matrix.root_size }} xz -T0 "build/$dish.img" - - name: Upload image and kickstart as artifact - if: github.ref == 'refs/heads/main' - uses: actions/upload-artifact@v3 - with: - name: ${{ matrix.edition }} - path: | - build/${{ env.DISH }}.img.xz - cook/dishes/${{ env.DISH }}.cfg - if-no-files-found: error - - name: Publish image and kickstart as release if: startsWith(github.ref, 'refs/tags/') uses: https://git.phyllo.me/devops/action-gh-release@v2