Skip to content

Commit a6cc870

Browse files
authored
Update GH-action for updating stats (#6632)
* Update stats-lambda.yml
1 parent b7ba06e commit a6cc870

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

.github/workflows/stats-lambda.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ permissions:
1111
id-token: write
1212

1313
on: # yamllint disable-line rule:truthy
14-
pull_request:
14+
pull_request_target:
1515
types:
1616
- closed
1717
branches:
@@ -23,7 +23,7 @@ env:
2323
AWS_REGION: "eu-west-1"
2424
jobs:
2525
if_merged:
26-
if: github.event.pull_request.merged == true
26+
if: (github.event.pull_request.merged == true) && (contains(github.event.pull_request.labels.*.name, 'On Call Review complete'))
2727
runs-on: ubuntu-latest
2828
name: GitHub Statistics
2929
steps:
@@ -34,7 +34,7 @@ jobs:
3434
uses: aws-actions/configure-aws-credentials@v4
3535
with:
3636
aws-region: ${{env.AWS_REGION}}
37-
role-to-assume: arn:aws:iam::959731285276:role/run-the-numbers-lambda
37+
role-to-assume: ${{ secrets.ROLE_ID }}
3838
output-credentials: true
3939
- name: Create payload
4040
run: echo "JSON_PAYLOAD={\"commit\" :\"${{ env.COMMIT }}\",\"author\" :\"${{ env.PR_AUTHOR }}\"}" >> $GITHUB_ENV

0 commit comments

Comments
 (0)