Skip to content

Commit c8b4d46

Browse files
[security] Set explicit permissions for GitHub Actions workflows (#887)
1 parent f746ba5 commit c8b4d46

File tree

4 files changed

+10
-0
lines changed

4 files changed

+10
-0
lines changed

.github/workflows/ci.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@ on:
77
jobs:
88
hygiene-tests:
99
name: Repository hygiene
10+
permissions:
11+
contents: read
1012
runs-on: ubuntu-latest
1113
steps:
1214
- name: Job information

.github/workflows/dev-checks.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
name: Developers environment checks
2+
permissions:
3+
contents: read
24
on:
35
pull_request: # All
46
push:

.github/workflows/image-publish.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@ on:
1414
# be the one found in scripts/tag.sh.
1515
# [1] https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#filter-pattern-cheat-sheet
1616
- "interuss/monitoring/v[0-9]+.[0-9]+.[0-9]+-?*"
17+
permissions:
18+
contents: read
1719
jobs:
1820
docker-hub-push:
1921
name: Build and Push to Docker Hub

.github/workflows/monitoring-test.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
name: 'Run a monitoring test (re-usable workflow)'
22

3+
# https://docs.github.com/en/actions/writing-workflows/workflow-syntax-for-github-actions#permissions
4+
permissions:
5+
contents: read
6+
37
on:
48
workflow_call:
59
inputs:

0 commit comments

Comments
 (0)