-
Notifications
You must be signed in to change notification settings - Fork 91
ci: Restrict deployment workflows to not run on forks #2617
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
ci: Restrict deployment workflows to not run on forks #2617
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #2617 +/- ##
=======================================
Coverage 98.23% 98.23%
=======================================
Files 65 65
Lines 4198 4198
Branches 592 592
=======================================
Hits 4124 4124
Misses 45 45
Partials 29 29
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
* Restrict workflows involving deployment or repository specific secrets to to only run on the scikit-hep/pyhf repository and not forks. * Also restrict workflows that run on nightly schedules so if there are failures it doesn't create noise on forks.
1f93daa to
10df187
Compare
|
I'm going to add copilot as a reviewer just to see what it says out of curiosity. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR restricts CI/CD workflows to run only on the main scikit-hep/pyhf repository and not on forks, improving the developer experience by preventing deployment-related workflow failures on forked repositories.
Key Changes:
- Added repository checks to deployment workflows (release tests, docs deployment, Docker registry logins)
- Added repository checks to scheduled dependency testing workflows
- Added repository checks to Codecov reporting steps
Reviewed Changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
.github/workflows/release_tests.yml |
Prevents PyPI release workflow from running on forks |
.github/workflows/docs.yml |
Restricts GitHub Pages deployment to main repository only |
.github/workflows/docker.yml |
Prevents Docker registry login attempts on forks |
.github/workflows/dependencies-head.yml |
Restricts all nightly dependency test jobs to main repository |
.github/workflows/ci.yml |
Prevents Codecov reporting from forks |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
Description
The motivation of this is to improve the developer experience of working on forks (which I'd like the devs to try to do too, not just contributors).
Checklist Before Requesting Reviewer
Before Merging
For the PR Assignees: