Skip to content

Commit

Permalink
CI: Fix missing explicit permissions for workflow runs
Browse files Browse the repository at this point in the history
Signed-off-by: Heathcliff <[email protected]>
  • Loading branch information
heathcliff26 committed Jan 4, 2025
1 parent a5a4d71 commit 90eef39
Show file tree
Hide file tree
Showing 6 changed files with 14 additions and 0 deletions.
6 changes: 6 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,14 +19,20 @@ on:
jobs:
lint:
uses: heathcliff26/ci/.github/workflows/golang-lint.yaml@main
permissions:
contents: read

unit-tests:
uses: heathcliff26/ci/.github/workflows/golang-unit-tests.yaml@main
permissions:
contents: read
with:
coveralls: ${{ github.event_name == 'pull_request' || github.event_name == 'merge_group' }}

validate:
uses: heathcliff26/ci/.github/workflows/golang-build.yaml@main
permissions:
contents: read
with:
cache: false
cmd: "make validate"
2 changes: 2 additions & 0 deletions .github/workflows/editorconfig-check.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,5 @@ on:
jobs:
check-editorconfig:
uses: heathcliff26/ci/.github/workflows/editorconfig-check.yaml@main
permissions:
contents: read
1 change: 1 addition & 0 deletions .github/workflows/go-testcover-report.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,6 @@ jobs:
generate-reports:
uses: heathcliff26/ci/.github/workflows/golang-testcover-report.yaml@main
secrets: inherit
permissions: {}
with:
coveralls: true
1 change: 1 addition & 0 deletions .github/workflows/link-check.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,6 @@ jobs:
check-links:
uses: heathcliff26/ci/.github/workflows/link-check.yaml@main
secrets: inherit
permissions: {}
with:
exclude-paths: "vendor"
2 changes: 2 additions & 0 deletions .github/workflows/renovate-config-validator.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,3 +20,5 @@ on:
jobs:
validate-renovate-config:
uses: heathcliff26/ci/.github/workflows/renovate-config-validator.yaml@main
permissions:
contents: read
2 changes: 2 additions & 0 deletions .github/workflows/renovate.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ env:
jobs:
prepare:
runs-on: ubuntu-latest
permissions: {}
outputs:
dry-run: ${{ steps.config.outputs.dry-run }}
log-level: "${{ steps.config.outputs.log-level }}"
Expand All @@ -40,6 +41,7 @@ jobs:
renovate:
needs: prepare
uses: heathcliff26/ci/.github/workflows/renovate.yaml@main
permissions: {}
with:
dry-run: ${{ needs.prepare.outputs.dry-run }}
log-level: "${{ needs.prepare.outputs.log-level }}"
Expand Down

0 comments on commit 90eef39

Please sign in to comment.