Skip to content

Commit 878925e

Browse files
committed
Auto merge of rust-lang#3909 - Kobzol:ci-permissions, r=RalfJung
Scope CI permissions to the job that needs it I scoped the permissions only to the job that requires them.
2 parents d47e254 + 8885ae9 commit 878925e

File tree

1 file changed

+5
-6
lines changed
  • src/tools/miri/.github/workflows

1 file changed

+5
-6
lines changed

src/tools/miri/.github/workflows/ci.yml

+5-6
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,6 @@ on:
1212
schedule:
1313
- cron: '44 4 * * *' # At 4:44 UTC every day.
1414

15-
permissions:
16-
# The cronjob needs to be able to push to the repo...
17-
contents: write
18-
# ... and create a PR.
19-
pull-requests: write
20-
2115
defaults:
2216
run:
2317
shell: bash
@@ -93,6 +87,11 @@ jobs:
9387
cron-fail-notify:
9488
name: cronjob failure notification
9589
runs-on: ubuntu-latest
90+
permissions:
91+
# The cronjob needs to be able to push to the repo...
92+
contents: write
93+
# ... and create a PR.
94+
pull-requests: write
9695
needs: [build, style]
9796
if: github.event_name == 'schedule' && failure()
9897
steps:

0 commit comments

Comments
 (0)