Skip to content

GH Actions: don't run cron jobs on forks#22851

Merged
jrfnl merged 1 commit intotrunkfrom
JRF/ghactions-dont-run-cronjobs-on-forks
Jan 3, 2026
Merged

GH Actions: don't run cron jobs on forks#22851
jrfnl merged 1 commit intotrunkfrom
JRF/ghactions-dont-run-cronjobs-on-forks

Conversation

@jrfnl
Copy link
Copy Markdown
Contributor

@jrfnl jrfnl commented Jan 3, 2026

Context

  • Improve CI

Summary

This PR can be summarized in the following changelog entry:

  • Improve CI

Relevant technical choices:

While workflows are disabled by default in forks, it is quite common for contributors to enable them to verify CI will pass before submitting a pull request.

When enabling workflow runs in forks, it's "all or nothing". This means that:

  • All workflows which are only intended to be run on the canonical repo will also be enabled. These workflows will also often need access to repo-specific secrets and will typically fail when run from a fork.
  • Workflows which contain cron jobs will also be enabled. Depending on the type of account the contributor has, this can burn through their "CI minutes".

This commit is based on a review of workflows containing cron jobs and disables running the jobs when a cron job is triggered in a fork.

Test instructions

Test instructions for the acceptance test before the PR gets merged

This PR can be acceptance tested by following these steps:

  • N/A

While workflows are disabled by default in forks, it is quite common for contributors to enable them to verify CI will pass before submitting a pull request.

When enabling workflow runs in forks, it's "all or nothing".
This means that:
* All workflows which are only intended to be run on the canonical repo will also be enabled.
    These workflows will also often need access to repo-specific secrets and will typically fail when run from a fork.
* Workflows which contain cron jobs will also be enabled.
    Depending on the type of account the contributor has, this can burn through their "CI minutes".

This commit is based on a review of workflows containing cron jobs and disables running the jobs when a cron job is triggered in a fork.
@jrfnl jrfnl added yoast cs/qa changelog: non-user-facing Needs to be included in the 'Non-userfacing' category in the changelog labels Jan 3, 2026
@jrfnl jrfnl merged commit 194fd73 into trunk Jan 3, 2026
12 checks passed
@jrfnl jrfnl deleted the JRF/ghactions-dont-run-cronjobs-on-forks branch January 3, 2026 03:44
@pls78 pls78 added this to the 26.8 milestone Jan 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

changelog: non-user-facing Needs to be included in the 'Non-userfacing' category in the changelog yoast cs/qa

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants