-
Notifications
You must be signed in to change notification settings - Fork 4.1k
29 lines (25 loc) · 1.01 KB
/
Copy pathlabeler.yml
File metadata and controls
29 lines (25 loc) · 1.01 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
name: "Pull Request Labeler"
on:
- pull_request
permissions:
contents: read
jobs:
triage:
# Only runs on the public grafana/loki repo: the loki-gh-app token broker isn't available elsewhere.
# We don't run the triaging for PRs from forks because those can't use the loki-gh-app token broker.
# We don't use GitHub actions app (secrets.GITHUB_TOKEN) because PRs created by the bot don't trigger CI.
if: ${{ github.repository == 'grafana/loki' && ! github.event.pull_request.head.repo.fork }}
runs-on: ubuntu-x64-small
permissions:
contents: read
pull-requests: write
id-token: write
steps:
- name: Generate GitHub App Token
id: app-token
uses: grafana/shared-workflows/actions/create-github-app-token@46f48da11e78ebdba7a8747ae456b11062fac83e # create-github-app-token/v0.3.1
with:
github_app: loki-gh-app
- uses: actions/labeler@b8dd2d9be0f68b860e7dae5dae7d772984eacd6d # v6.2.0
with:
repo-token: "${{ steps.app-token.outputs.token }}"