ci: allow merged fork subject checkout - #443
Conversation
LeftHandCold
left a comment
There was a problem hiding this comment.
Reviewed exact head d993817cd39a10ed1ae2412c48dbcbc1b243e3f5.
The runtime/security direction is correct: checkout v6 now requires this explicit opt-in for fork-originated pull_request_target subjects, while this reusable workflow admits only an already-merged PR, verifies the exact 40-hex merge SHA, and passes that verified immutable SHA to the two downstream MatrixOne checkouts. The added contract tests cover the intended inventory and merged-only guard.
One objective delivery blocker remains. The repository pins actionlint v1.7.12, released before allow-unsafe-pr-checkout was backported to checkout v6, so its embedded action schema rejects all three new inputs. The exact-head required check fails before the subject-contract tests run. Please align the repository validator with the current checkout v6 metadata (or add a narrowly scoped temporary ignore for this exact input/file) and rerun the required workflow green. I found no other security, subject-identity, or workflow-control blocker.
LeftHandCold
left a comment
There was a problem hiding this comment.
Re-reviewed exact head 3dc1e162164894bdcef48057defc37059197fddc.
The prior delivery blocker is closed. Since actionlint v1.7.12 is still the latest release and predates checkout v6's new input, the added workaround is appropriately narrow: it is scoped only to .github/workflows/merge-trigger-tke.yaml and matches only the exact allow-unsafe-pr-checkout diagnostic for actions/checkout@v6.
The exact-head required run 33606369688 is green: the full actionlint invocation passed, then all five merged-subject contract tests ran and passed. The production workflow remains limited to merged PRs, verifies the immutable merge SHA, and carries only that verified SHA into the two downstream MatrixOne checkouts. No remaining security, correctness, workflow-control, or delivery blocker found.
What changed
actions/checkout@v6to check out the exact merged subject for fork-originated PRs.Why
actions/checkout@v6now rejects a customizedmerge_commit_shafrom a fork-originatedpull_request_targetevent unlessallow-unsafe-pr-checkoutis explicitly enabled. MatrixOne run 33566831590 therefore failed before the Docker build and skipped all downstream tests.The build job already requires
github.event.pull_request.merged == true, and the workflow continues to verify that the checked-out HEAD equalsmerge_commit_sha. This preserves PR #441's exact merged-subject behavior for release branches.Verification
python3 scripts/test_merge_trigger_tke_subject.py -v(5 tests passed)actionlint v1.7.12