Skip to content
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: Prevent certain checks from running on forked PRs #16047

Open
wants to merge 27 commits into
base: develop
Choose a base branch
from

Conversation

andrewb1269hg
Copy link
Contributor

@andrewb1269hg andrewb1269hg commented Oct 18, 2024

Description:
Add a check for a forked repo to any workflow file steps which use secrets.* token or default GITHUB_TOKEN.

Related Issue(s):
Fixes #16004

@andrewb1269hg andrewb1269hg linked an issue Oct 18, 2024 that may be closed by this pull request
@andrewb1269hg andrewb1269hg self-assigned this Oct 18, 2024
@andrewb1269hg andrewb1269hg added this to the v0.56 milestone Oct 18, 2024
Copy link

github-actions bot commented Oct 18, 2024

Node: HAPI Test (Restart) Results

9 files  1 errors  8 suites   7m 50s ⏱️
7 tests 7 ✅ 0 💤 0 ❌
8 runs  8 ✅ 0 💤 0 ❌

For more details on these parsing errors, see this check.

Results for commit d62de25.

♻️ This comment has been updated with latest results.

Copy link

codacy-production bot commented Oct 18, 2024

Coverage summary from Codacy

See diff coverage on Codacy

Coverage variation Diff coverage
+0.00% (target: -1.00%)
Coverage variation details
Coverable lines Covered lines Coverage
Common ancestor commit (df149d7) 97511 63616 65.24%
Head commit (1346368) 97522 (+11) 63622 (+6) 65.24% (+0.00%)

Coverage variation is the difference between the coverage for the head and common ancestor commits of the pull request branch: <coverage of head commit> - <coverage of common ancestor commit>

Diff coverage details
Coverable lines Covered lines Diff coverage
Pull request (#16047) 0 0 ∅ (not applicable)

Diff coverage is the percentage of lines that are covered by tests out of the coverable lines that the pull request added or modified: <covered lines added or modified>/<coverable lines added or modified> * 100%

See your quality gate settings    Change summary preferences

Codacy stopped sending the deprecated coverage status on June 5th, 2024. Learn more

Copy link

codecov bot commented Oct 18, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 63.53%. Comparing base (df149d7) to head (1346368).
Report is 5 commits behind head on develop.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             develop   #16047   +/-   ##
==========================================
  Coverage      63.53%   63.53%           
- Complexity     20370    20372    +2     
==========================================
  Files           2537     2537           
  Lines          94746    94757   +11     
  Branches        9902     9904    +2     
==========================================
+ Hits           60198    60206    +8     
- Misses         30941    30946    +5     
+ Partials        3607     3605    -2     

see 14 files with indirect coverage changes

Impacted file tree graph

@andrewb1269hg andrewb1269hg changed the title ci: Add fork repo check in workflows ci: Prevent certain checks from running on forked PRs Oct 18, 2024
@andrewb1269hg andrewb1269hg marked this pull request as ready for review October 21, 2024 11:18
@andrewb1269hg andrewb1269hg requested review from a team as code owners October 21, 2024 11:18
@andrewb1269hg andrewb1269hg force-pushed the 16004-prevent-certain-checks-from-running-on-forked-prs branch from 47a7e08 to 2b822a9 Compare October 21, 2024 11:34
**Description**:
Add a check to any workflow file steps which use secrets.* token or default GITHUB_TOKEN.

**Related Issue(s)**:

Signed-off-by: Andrew Brandt <[email protected]>
@andrewb1269hg andrewb1269hg force-pushed the 16004-prevent-certain-checks-from-running-on-forked-prs branch from 2b822a9 to 3a70aef Compare October 21, 2024 11:37
.github/workflows/node-flow-build-application.yaml Outdated Show resolved Hide resolved
.github/workflows/flow-node-performance-tests.yaml Outdated Show resolved Hide resolved
.github/workflows/flow-node-performance-tests.yaml Outdated Show resolved Hide resolved
.github/workflows/flow-node-performance-tests.yaml Outdated Show resolved Hide resolved
.github/workflows/node-flow-deploy-adhoc-artifact.yaml Outdated Show resolved Hide resolved
.github/workflows/node-flow-deploy-preview.yaml Outdated Show resolved Hide resolved
.github/workflows/node-flow-deploy-release-artifact.yaml Outdated Show resolved Hide resolved
.github/workflows/node-flow-deploy-release-artifact.yaml Outdated Show resolved Hide resolved
.github/workflows/node-flow-fsts-custom-regression.yaml Outdated Show resolved Hide resolved
.github/workflows/flow-node-performance-tests.yaml Outdated Show resolved Hide resolved
.github/workflows/flow-pull-request-formatting.yaml Outdated Show resolved Hide resolved
.github/workflows/node-flow-deploy-release-artifact.yaml Outdated Show resolved Hide resolved
.github/workflows/node-flow-fsts-daily-interval-01.yaml Outdated Show resolved Hide resolved
.github/workflows/node-flow-fsts-daily-interval-01.yaml Outdated Show resolved Hide resolved
.github/workflows/node-flow-pull-request-checks.yaml Outdated Show resolved Hide resolved
.github/workflows/node-flow-pull-request-checks.yaml Outdated Show resolved Hide resolved
.github/workflows/node-flow-pull-request-checks.yaml Outdated Show resolved Hide resolved
.github/workflows/node-flow-pull-request-checks.yaml Outdated Show resolved Hide resolved
.github/workflows/node-flow-pull-request-checks.yaml Outdated Show resolved Hide resolved
@rbarkerSL rbarkerSL marked this pull request as draft October 21, 2024 22:25
@andrewb1269hg andrewb1269hg force-pushed the 16004-prevent-certain-checks-from-running-on-forked-prs branch from 6557505 to e2a981d Compare October 22, 2024 19:12
@andrewb1269hg andrewb1269hg force-pushed the 16004-prevent-certain-checks-from-running-on-forked-prs branch from ec1e411 to 9eab51e Compare October 22, 2024 19:28
@andrewb1269hg andrewb1269hg marked this pull request as ready for review October 23, 2024 15:40
@andrewb1269hg
Copy link
Contributor Author

Major updates:

  1. Removed all workflow_dispatch checks.
  2. Added checks to workflow_call files.
  3. Reformat and standardize the order of if-check stanzas inside steps.

rbarkerSL
rbarkerSL previously approved these changes Oct 23, 2024
@rbarkerSL rbarkerSL self-requested a review October 29, 2024 14:06
rbarkerSL
rbarkerSL previously approved these changes Oct 29, 2024
Co-authored-by: Nathan Klick <[email protected]>
Signed-off-by: Andrew Brandt <[email protected]>
rbarkerSL
rbarkerSL previously approved these changes Nov 5, 2024
rbarkerSL
rbarkerSL previously approved these changes Nov 26, 2024
rbarkerSL
rbarkerSL previously approved these changes Nov 26, 2024
.github/workflows/node-zxc-build-release-artifact.yaml Outdated Show resolved Hide resolved
.github/workflows/node-zxc-build-release-artifact.yaml Outdated Show resolved Hide resolved
.github/workflows/node-zxc-build-release-artifact.yaml Outdated Show resolved Hide resolved
.github/workflows/node-zxc-build-release-artifact.yaml Outdated Show resolved Hide resolved
.github/workflows/node-zxc-build-release-artifact.yaml Outdated Show resolved Hide resolved
.github/workflows/node-zxc-build-release-artifact.yaml Outdated Show resolved Hide resolved
.github/workflows/node-zxc-build-release-artifact.yaml Outdated Show resolved Hide resolved
.github/workflows/node-zxc-compile-application-code.yaml Outdated Show resolved Hide resolved
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.

Prevent certain checks from running on forked PRs
3 participants