Skip to content

Commit bd04a97

Browse files
committed
ci: set permissions in parent job.
1 parent 4f370e5 commit bd04a97

File tree

3 files changed

+13
-0
lines changed

3 files changed

+13
-0
lines changed

.github/workflows/cicd.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,9 @@ jobs:
3232
ci:
3333
needs: [setup]
3434
uses: ./.github/workflows/pipeline.yaml
35+
permissions:
36+
checks: write
37+
contents: write
3538
with:
3639
effective-branch: ${{ needs.setup.outputs.effective-branch }}
3740
release: ${{ needs.setup.outputs.release == 'true' }}

.github/workflows/docs.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@ on:
77
jobs:
88
deploy:
99
runs-on: ubuntu-latest
10+
permissions:
11+
contents: write
1012
steps:
1113
- uses: actions/checkout@v4
1214
- uses: actions/[email protected]

.github/workflows/pipeline.yaml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,14 +29,20 @@ on:
2929
jobs:
3030
validate:
3131
uses: ./.github/workflows/validate.yaml
32+
permissions:
33+
checks: write
3234

3335
integ-test:
3436
uses: ./.github/workflows/integ-test.yaml
37+
permissions:
38+
checks: write
3539

3640
release:
3741
needs: [validate, integ-test]
3842
if: ${{ inputs.release || inputs.effective-branch == 'develop' }}
3943
uses: ./.github/workflows/release.yaml
44+
permissions:
45+
contents: write
4046
with:
4147
effective-branch: ${{ inputs.effective-branch }}
4248
release: ${{ inputs.release }}
@@ -47,6 +53,8 @@ jobs:
4753
needs: [validate, integ-test]
4854
if: ${{ inputs.release }}
4955
uses: ./.github/workflows/maven-publish.yaml
56+
permissions:
57+
contents: write
5058
secrets: inherit
5159

5260
distroless:

0 commit comments

Comments
 (0)