Skip to content

Commit e6b95fb

Browse files
committed
Restrict GITHUB_TOKEN default permission
1 parent 0915ae7 commit e6b95fb

File tree

2 files changed

+11
-0
lines changed

2 files changed

+11
-0
lines changed

.github/repository-settings.md

+5
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,11 @@ settings](https://github.com/open-telemetry/community/blob/main/docs/how-to-conf
1818
(To reduce friction for new contributors,
1919
as the default is "Require approval for first-time contributors")
2020

21+
- Workflow permissions
22+
- Default permissions granted to the `GITHUB_TOKEN` when running workflows in this repository:
23+
Read repository contents and packages permissions
24+
- Allow GitHub Actions to create and approve pull requests: UNCHECKED
25+
2126
## Branch protections
2227

2328
The order of branch protection rules

.github/workflows/assign-reviewers.yml

+6
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,14 @@ on:
88
# because repository write permission is needed to assign reviewers
99
pull_request_target:
1010

11+
permissions:
12+
contents: read
13+
1114
jobs:
1215
assign-reviewers:
16+
permissions:
17+
contents: read
18+
pull-requests: write
1319
runs-on: ubuntu-latest
1420
steps:
1521
- uses: trask/component-owners@02dfde3c03025c064cc6961975e28a42e81c394a # main

0 commit comments

Comments
 (0)