Unverified Commit 7267ceee authored by Sebastian "Sebbie" Silbermann's avatar Sebastian "Sebbie" Silbermann Committed by GitHub

[ci] Populate GITHUB_TOKEN for auto-labeler (#93219)

parent 0fdd6902
......@@ -4,11 +4,13 @@ description: >-
the config in this action's src/config.json.
# This action deliberately has no inputs. It reads `GITHUB_TOKEN` from the
# environment, which GitHub Actions populates with the job's own token.
# Exposing a `github-token` input would let callers pass an unrelated
# (potentially higher-privileged) token from a fork-controlled context;
# forcing the use of the job token keeps the principle of least privilege
# tied to the workflow's declared `permissions:` block.
# environment, which the calling workflow must set via `env:` — typically
# to `${{ secrets.GITHUB_TOKEN }}`, the job's own token scoped by the
# workflow's `permissions:` block. Exposing a `github-token` input would
# let callers pass an unrelated (potentially higher-privileged) token from
# a fork-controlled context; forcing the use of the job token via `env:`
# keeps the principle of least privilege tied to the workflow's declared
# `permissions:` block.
runs:
using: 'node24'
main: 'dist/index.js'
......@@ -59,9 +59,9 @@ jobs:
if: github.repository_owner == 'vercel'
runs-on: ubuntu-latest
permissions:
# To checkout the action
contents: read
# To add labels
pull-requests: write
steps:
- uses: vercel/next.js/.github/actions/pr-auto-label@canary
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment