From 719cfee2ca3323bf18624dcf4611f963a9ed0013 Mon Sep 17 00:00:00 2001 From: Justin Paul Date: Sun, 24 May 2026 14:27:31 -0400 Subject: [PATCH] ci: add concurrency control to image-only.yml MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Two rapid commits today (2acba0a → c5ed556) queued back-to-back runs of the same workflow. Each run is ~90 min (the reindex is the long pole), and the older commit's image just gets overwritten by the newer one anyway — so the older run is pure waste. concurrency: group: image-only cancel-in-progress: true cancels any in-flight run on the same workflow when a new push lands. Future-me will thank present-me. (The workflow-file change doesn't itself trigger image-only.yml since .gitea/workflows/** isn't in the paths: filter — so this commit doesn't kick off a third run.) Co-Authored-By: Claude Opus 4.7 (1M context) --- .gitea/workflows/image-only.yml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/.gitea/workflows/image-only.yml b/.gitea/workflows/image-only.yml index 1692f4e..6c91d9b 100644 --- a/.gitea/workflows/image-only.yml +++ b/.gitea/workflows/image-only.yml @@ -20,6 +20,13 @@ on: - "Dockerfile" - "sources.json" +# If multiple pushes land in quick succession, cancel the older one +# rather than queueing both — each run is ~90 min and the older +# commit's image just gets overwritten by the newer one anyway. +concurrency: + group: image-only + cancel-in-progress: true + env: REGISTRY_PUSH: 192.168.0.2:1234 REGISTRY_PULL: git.jpaul.io