We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 94b5973 commit 1761740Copy full SHA for 1761740
.github/workflows/test.yaml
@@ -21,8 +21,11 @@ jobs:
21
matrix:
22
tf: [tofu, terraform]
23
steps:
24
+ # Only checkout for pull_request_target events (not for push to main)
25
+ # pull_request_target runs in the context of the base branch for security,
26
+ # so we must explicitly checkout the PR's head commit to test the actual changes
27
- name: Checkout PR Head
- if: github.event_name == 'pull_request_target'
28
+ if: github.event_name != 'push'
29
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
30
with:
31
ref: ${{ github.event.pull_request.head.sha }}
0 commit comments