Skip to content

Commit d7a70cb

Browse files
lbroudouxSebastienDegodez
authored andcommitted
chore(ci): microcks#97 Specify the most restrictive permissions
Signed-off-by: Laurent Broudoux <[email protected]>
1 parent e18aee4 commit d7a70cb

File tree

6 files changed

+15
-0
lines changed

6 files changed

+15
-0
lines changed

.github/workflows/cicd.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,8 @@ permissions: read-all
2424
jobs:
2525
version:
2626
name: Define Version
27+
permissions:
28+
contents: read
2729
uses: ./.github/workflows/steps.dotnet-version.yml
2830
with:
2931
runs-on: ubuntu-latest

.github/workflows/steps.dotnet-build-test.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,8 @@
2323
publish-package:
2424
description: 'Publish package is enabled ?'
2525
value: ${{ jobs.build_test.outputs.publish-package }}
26+
permissions: read-all
27+
2628
jobs:
2729
build_test:
2830
runs-on: ${{ inputs.runs-on }}

.github/workflows/steps.dotnet-nuget-publish.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@ on:
88
secrets:
99
NUGET_KEY:
1010
required: true
11+
permissions: read-all
12+
1113
jobs:
1214
nuget-publish:
1315
if: ${{ github.event_name != 'pull_request' && github.repository == 'microcks/microcks-testcontainers-dotnet' }}

.github/workflows/steps.dotnet-version.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@
1515
majorMinorPatch:
1616
description: 'majorMinorPatch (gitversion)'
1717
value: ${{ jobs.define_version.outputs.majorMinorPatch }}
18+
permissions: read-all
19+
1820
jobs:
1921
define_version:
2022
runs-on: ${{ inputs.runs-on }}

.github/workflows/steps.github-release-draft.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,9 @@
1212
jobs:
1313
release_drafter:
1414
if: ${{ github.event_name != 'pull_request' && github.ref == 'refs/heads/main' }}
15+
permissions:
16+
contents: write
17+
deployments: write
1518
runs-on: ${{ inputs.runs-on }}
1619
steps:
1720
- name: 🔄 Checkout

.github/workflows/steps.publish-test-reporter.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,10 @@
55
required: false
66
type: string
77
default: 'ubuntu-latest'
8+
permissions:
9+
contents: read
10+
actions: read
11+
checks: write
812

913
jobs:
1014
report:

0 commit comments

Comments
 (0)