Skip to content

ci: keep upstream workflows quiet between fork-sync runs - #18

Merged
ibetitsmike merged 5 commits into
mainfrom
mike/fix-issue-14-quiet-upstream-workflows
Nov 8, 2026
Merged

ibetitsmike merged 5 commits into
mainfrom
mike/fix-issue-14-quiet-upstream-workflows

Conversation

@ibetitsmike

@ibetitsmike ibetitsmike commented Nov 8, 2026 •

Copy link
Copy Markdown
Owner

Xum opened this PR on behalf of @ibetitsmike.

Part of #14.

GitHub registers a workflow, active, the first time an event matches it, and an unregistered workflow cannot be disabled in advance (GET /actions/workflows/<file> returns 404). Only fork-sync disabled upstream workflows, once a day, so a workflow registered in between ran freely until the next sync.

The new fork-quiet workflow disables every active non-fork-* workflow and then force-cancels unfinished runs of those workflows. A plain cancel still runs the always() steps of upstream jobs. It runs hourly and on the events upstream's workflows use: push, create, pull_request, issues, issue_comment and release. A new upstream workflow now stays active for minutes, not a day, and a run that starts on the same event is usually cancelled before it finishes. fork-sync calls it as a reusable workflow instead of keeping its own copy. Both files set top-level permissions: {} and grant per job (actions: write for the quiet job, contents: read for sync).

Options I rejected:

  • Deleting upstream workflow files from the fork, or adding a fork guard to each one. Both turn every upstream workflow change into a sync conflict.
  • Limiting allowed actions in the repository settings. It does not block workflows that only use run: steps.

Remaining gap: an upstream workflow that a schedule or a PR from another repository registers stays active until the next hourly pass, which then cancels its run if it is still going. Parallel fork-quiet runs are safe: a run whose disable fails passes only if the workflow is no longer active. The README's new "Upstream workflows" section documents this.

Validation: actionlint (pinned to the mise.toml revision, with shellcheck) passes on fork-*.yaml. zizmor 1.11.0 reports only the artipacked finding that already existed on fork-sync's sync checkout. No dashes. markdownlint gives the same 7 table-style errors as main. The test audit found no tests to add or change. Polish and the test audit stayed inside the three changed files.

Remote UAT: skipped. The change is GitHub Actions configuration only and does not touch the Coder server, so the evidence below comes from this PR's own Actions runs.

Actions evidence

  • fork-quiet runs on this PR's head and on the merge to main, all green:
    • push: 42529309737, 42529511995, 42530480729
    • create: 42529309903
    • pull_request: 42529337588, 42529516432, 42530483858, 42530484246, 42532065704
    • on main after the merge: push 42532065122, issues 42532067740, issue_comment 42532077245
  • The force-cancel in runs 42529511995 and 42529516432 ended upstream weekly-docs run 42526199687, which had been in_progress since 21:38 UTC. A plain cancel in the earlier runs did not stop it. It is now completed/cancelled.
  • fork-ci on the head (85f532d445): green, run 42530484389.
  • Active workflows after the change ran, from gh api repos/ibetitsmike/coder/actions/workflows --paginate at 2026-11-08 22:49 UTC: only fork-ci.yaml and fork-quiet.yaml. These 17 are disabled_manually: backport, cherry-pick, ci, contrib, dependabot, deploy-docs, doc-check, docs-preview, eval-coder-agents, flake-go, fork-sync, linear-release, pr-auto-assign, scorecard, stale, triage-via-chat-api, weekly-docs. fork-sync was turned off on GitHub separately, because the upstream sync now runs locally.

Add a fork-quiet workflow that disables active non-fork workflows and
cancels their unfinished runs on the events upstream workflows use and
hourly. fork-sync calls it as a reusable workflow.

Fixes #14
@ibetitsmike

Copy link
Copy Markdown
Owner Author

Xum commented on behalf of @ibetitsmike.

@codex review

@ibetitsmike

Copy link
Copy Markdown
Owner Author

@codex review

@ibetitsmike

Copy link
Copy Markdown
Owner Author

@codex review

@ibetitsmike

Copy link
Copy Markdown
Owner Author

@codex review

@ibetitsmike

Copy link
Copy Markdown
Owner Author

Xum (AI agent) merged this on Mike's behalf as the pstack parity lead.

Lead merge check on head 85f532d445: fork-ci green (run 42530484389), 0 unresolved threads, interim Opus code-quality-review PASS (Codex has not answered @codex review), UAT not applicable (Actions config only). After the merge I will dispatch fork-sync to prove the workflow_call path.

@ibetitsmike
ibetitsmike merged commit b3a57df into main Nov 8, 2026
7 checks passed
@ibetitsmike
ibetitsmike deleted the mike/fix-issue-14-quiet-upstream-workflows branch November 8, 2026 22:48
@chatgpt-codex-connector

Copy link
Copy Markdown

To use Codex here, create an environment for this repo.

@ibetitsmike

Copy link
Copy Markdown
Owner Author

Xum (AI agent) posted this on Mike's behalf as the pstack parity lead.

Correction to my merge note: the Actions fork-sync workflow is disabled (upstream sync now runs on Mike's Mac through coder-local-sync), so I did not dispatch it. Post-merge evidence instead: fork-quiet ran green on main for push (42532065122), issues (42532067740) and issue_comment (42532077245). The README wording about "before every sync" gets a follow-up PR under #14.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant