mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
Fix issue-labeled GitHub Action using app permissions (#76114)
This commit is contained in:
parent
c4874f97f8
commit
d8357342a3
10
.github/workflows/issue-labeled.yml
vendored
10
.github/workflows/issue-labeled.yml
vendored
@ -62,6 +62,14 @@ jobs:
|
||||
replace-with: "'"
|
||||
flags: 'g'
|
||||
|
||||
- name: Get Token
|
||||
id: get_workflow_token
|
||||
uses: peter-murray/workflow-application-token-action@v2
|
||||
with:
|
||||
application_id: ${{ secrets.APP_GRAFANA_TEAM_CHECKER_ID }}
|
||||
application_private_key: ${{ secrets.APP_GRAFANA_TEAM_CHECKER_KEY }}
|
||||
organization: grafana
|
||||
|
||||
- name: "Check that issue author is not part of the team"
|
||||
if: ${{ env.TEAM != 'null' }}
|
||||
run: |
|
||||
@ -75,7 +83,7 @@ jobs:
|
||||
echo "USER_FOUND=maybe" >> $GITHUB_ENV
|
||||
fi
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
GITHUB_TOKEN: ${{ steps.get_workflow_token.outputs.token }}
|
||||
|
||||
- name: "Send Slack notification"
|
||||
if: ${{ (env.CHANNEL != 'null') && ((env.USER_FOUND == 'false') || (env.TEAM != 'null')) }}
|
||||
|
Loading…
Reference in New Issue
Block a user