Skip to content

Prevent PR builds from running on forks #8993

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged

Conversation

elliedori
Copy link
Contributor

An issue was raised in Spring Session (spring-projects/spring-session#1678) detailing how builds were running on forked versions of the repo. I fixed the issue in #8698, this PR adds similar logic to the Spring Security repo to ensure builds don't run on forks.

More detail:

Github Actions doesn't currently have an elegant way to prevent builds on forks. Following the suggestion outlined here, I added checks for each job to ensure it only runs on spring-projects/spring-session.

I opened a PR on my forked version and confirmed that no builds steps ran. See https://github.com/elliedori/spring-security/pull/6/checks?check_run_id=1062839692 for more.

@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged label Sep 2, 2020
@rwinch rwinch added in: build An issue in the build type: enhancement A general enhancement and removed status: waiting-for-triage An issue we've not yet triaged labels Oct 26, 2020
@rwinch rwinch added this to the 5.5.0-M1 milestone Oct 26, 2020
@rwinch rwinch merged commit d69032a into spring-projects:master Oct 26, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
in: build An issue in the build type: enhancement A general enhancement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants