From a89a5576a306fadbb1c0d1dfaa271070457defc1 Mon Sep 17 00:00:00 2001 From: Rootiest Date: Mon, 31 Aug 2026 20:19:40 -0400 Subject: [PATCH] fix(ci): skip queued-forever jobs on the GitHub mirror The test/build-docs jobs target a self-hosted runner (racknerd-mini) that only exists on the Gitea instance. When GitHub re-runs this same workflow on the mirror, those jobs sit queued forever with no matching runner, so the commit never gets a completed status. Gate both jobs to skip when github.server_url is github.com, and add a trivial github-mirror job (runs-on: ubuntu-latest, which GitHub does provide) that only runs on the mirror, so the check completes instead of hanging. --- .github/workflows/ci.yml | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 66157f3..2ddd174 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -29,8 +29,15 @@ on: - build-docs jobs: + # This workflow file is mirrored to GitHub as-is, but the runner label + # below (racknerd-mini) only exists on the Gitea instance -- on GitHub + # the job just sits queued forever with no matching runner, so the + # mirror never gets a completed status. Gate the real jobs to Gitea and + # let the github-mirror job below stand in on GitHub instead. test: - if: github.event_name != 'workflow_dispatch' || github.event.inputs.job == 'all' || github.event.inputs.job == 'test' + if: | + github.server_url != 'https://github.com' && + (github.event_name != 'workflow_dispatch' || github.event.inputs.job == 'all' || github.event.inputs.job == 'test') runs-on: racknerd-mini steps: - name: Checkout @@ -52,6 +59,7 @@ jobs: build-docs: needs: test if: | + github.server_url != 'https://github.com' && always() && (github.event.inputs.job == 'build-docs' || ((github.event_name != 'workflow_dispatch' || github.event.inputs.job == 'all') && @@ -126,3 +134,15 @@ jobs: git diff --cached --quiet && echo "No changes to commit" && exit 0 git commit -m "chore(docs): regenerate manual, man page, and component registry" git push + + # Stand-in for the GitHub mirror so the commit gets a completed status + # instead of the real jobs above sitting queued forever for a + # self-hosted runner that only exists on the Gitea instance. + github-mirror: + if: github.server_url == 'https://github.com' + runs-on: ubuntu-latest + steps: + - name: Note that CI runs on Gitea + run: | + echo "This repository mirrors from Gitea (git.rootiest.dev), where CI actually runs." + echo "See the commit's status on the Gitea instance for the real test/build-docs results."