Skip to content

Auto-close PRs from forks#166

Merged
khsrali merged 3 commits into
mainfrom
ci/close-fork-prs
May 8, 2026
Merged

Auto-close PRs from forks#166
khsrali merged 3 commits into
mainfrom
ci/close-fork-prs

Conversation

@khsrali
Copy link
Copy Markdown
Contributor

@khsrali khsrali commented May 8, 2026

Cloudflare Pages doesn't build preview deployments for fork PRs (its build env can hold project secrets, so untrusted code is hard-refused — see CF docs). The Read-the-Docs-style "previews on forks" we used to have only worked because RTD's build had no secrets to protect. Restoring fork previews on CF would mean a two-stage GitHub Actions workflow (build artifact in untrusted context → deploy via CF API token in trusted context), which is real CI surface to maintain for a project that is mostly maintainer-driven. Auto-closing fork PRs with a clear comment is the lower-cost path; we can revisit if community contributions pick up.

Note: opening PRs on this repo from the community is discouraged anyways, we recommend that they open issues, and leave the implementation to us.

@cloudflare-workers-and-pages
Copy link
Copy Markdown

cloudflare-workers-and-pages Bot commented May 8, 2026

Deploying aiida-website with  Cloudflare Pages  Cloudflare Pages

Latest commit: ed5106d
Status: ✅  Deploy successful!
Preview URL: https://7950e0b2.aiida-website.pages.dev
Branch Preview URL: https://ci-close-fork-prs.aiida-website.pages.dev

View logs

Comment thread README.md Outdated

This repository is maintained by the AiiDA team, and we **discourage external pull requests** as a matter of policy. If you spot a typo, a broken link, outdated content, or have an idea you'd like to see on the site, please [**open an issue**](https://github.com/aiidateam/aiida-website/issues/new) describing the change — we'll handle the implementation. PRs opened from forks are auto-closed with a comment redirecting to Issues.

The reasoning is twofold: (1) we want a single editorial voice across the site, so changes flow through the team rather than landing piecemeal; and (2) Cloudflare Pages doesn't build preview deployments for fork PRs (a security default — the build environment can hold project secrets), so a fork PR can't be reviewed visually anyway. The Issues path keeps the loop short for everyone.
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
The reasoning is twofold: (1) we want a single editorial voice across the site, so changes flow through the team rather than landing piecemeal; and (2) Cloudflare Pages doesn't build preview deployments for fork PRs (a security default — the build environment can hold project secrets), so a fork PR can't be reviewed visually anyway. The Issues path keeps the loop short for everyone.
The reasoning is twofold: (1) we want a single editorial voice across the site, so changes flow through the team rather than landing piecemeal; and (2) Cloudflare Pages doesn't build preview deployments for fork PRs (a security default — the build environment can hold project secrets), so a fork PR can't be reviewed visually anyway (there are workarounds but whatever). The Issues path keeps the loop short for everyone.

@khsrali khsrali force-pushed the ci/close-fork-prs branch from 7e68501 to 093a484 Compare May 8, 2026 12:05
Comment thread .github/workflows/close-fork-prs.yml Outdated
Comment thread .github/workflows/close-fork-prs.yml
@khsrali khsrali merged commit d12d1e4 into main May 8, 2026
3 checks passed
@khsrali khsrali deleted the ci/close-fork-prs branch May 8, 2026 12:18
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