Skip to content

Commit 308115c

Browse files
committed
Fix CI and GitLeaks GitHub actions permissions (2)
1 parent 28da7b9 commit 308115c

2 files changed

Lines changed: 10 additions & 6 deletions

File tree

.github/workflows/ci.yml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,10 @@ on:
55
branches:
66
- "**"
77

8+
permissions:
9+
contents: read
10+
pull-requests: write
11+
812
jobs:
913
build:
1014
runs-on: ubuntu-latest
@@ -28,8 +32,5 @@ jobs:
2832

2933
- name: Run Makefile target
3034
run: make
31-
permissions:
32-
contents: read
33-
pull-requests: write
3435
env:
3536
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/gitleaks.yml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,16 @@
11
name: Gitleaks
2+
23
on:
34
push:
45
pull_request:
56
workflow_dispatch:
67
schedule:
78
- cron: "0 4 * * *" # run once a day at 4 AM
9+
10+
permissions:
11+
contents: read
12+
pull-requests: write
13+
814
jobs:
915
scan:
1016
name: Gitleaks
@@ -17,8 +23,5 @@ jobs:
1723

1824
- name: Run Gitleaks
1925
uses: gitleaks/gitleaks-action@v2
20-
permissions:
21-
contents: read
22-
pull-requests: write
2326
env:
2427
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)