Skip to content

Commit

Permalink
ci(assign): define permissions for auto assign workflow
Browse files Browse the repository at this point in the history
Explicitely stating required permissions is considered best practice.
This case was detected by Poutine, see
https://github.com/boostsecurityio/poutine/blob/main/docs/content/en/rules/default_permissions_on_risky_events.md.

Signed-off-by: Florian Greinacher <[email protected]>
  • Loading branch information
fgreinacher committed May 3, 2024
1 parent 7328ad3 commit e37ff81
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions .github/workflows/assign.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,10 @@ on:
pull_request:
types: [opened, ready_for_review]

permissions:
contents: read # to read configuration file
pull-requests: write # to assign PRs

jobs:
add-reviews:
runs-on: ubuntu-latest
Expand Down

0 comments on commit e37ff81

Please sign in to comment.