File tree Expand file tree Collapse file tree 1 file changed +13
-2
lines changed Expand file tree Collapse file tree 1 file changed +13
-2
lines changed Original file line number Diff line number Diff line change 1
1
---
2
2
name : Amplify Security
3
3
on :
4
- pull_request : {}
4
+ pull_request_target : {}
5
5
workflow_dispatch : {}
6
6
push :
7
7
branches : ["main", "develop"]
@@ -11,12 +11,23 @@ permissions:
11
11
id-token : write
12
12
13
13
jobs :
14
+ authorize :
15
+ environment :
16
+ ${{ github.event_name == 'pull_request_target' &&
17
+ github.event.pull_request.head.repo.fork && 'external' || 'internal' }}
18
+ runs-on : ubuntu-latest
19
+ steps :
20
+ - run : true
21
+
14
22
amplify-security-scan :
15
23
name : Amplify Security Scan
24
+ needs : authorize
16
25
runs-on : ubuntu-latest
17
- if : (! github.event.pull_request.head.repo.fork && github. actor != 'dependabot[bot]')
26
+ if : github.actor != 'dependabot[bot]'
18
27
steps :
19
28
- name : Checkout
20
29
uses : actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
30
+ with :
31
+ ref : ${{ github.event.pull_request.head.sha || github.ref }}
21
32
- name : Amplify Runner
22
33
uses : amplify-security/runner-action@926f003f3c9695a93cbc4e2f1e64eb784dcacbfc # v0.2.0
You can’t perform that action at this time.
0 commit comments