Skip to content

Commit

Permalink
Infra: Fix permissions for checkout (#28)
Browse files Browse the repository at this point in the history
  • Loading branch information
mrmoonl1ght94 authored Jan 23, 2024
1 parent 7b02579 commit 9186cd0
Show file tree
Hide file tree
Showing 17 changed files with 41 additions and 9 deletions.
3 changes: 2 additions & 1 deletion .github/workflows/backend.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,10 @@ on:
paths:
- "kafka-ui-api/**"
- "pom.xml"
permissions:
permissions: # TODO remove when public
checks: write
pull-requests: write
contents: read
jobs:
build-and-test:
runs-on: ubuntu-latest
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/branch-deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ jobs:
build:
if: ${{ github.event.label.name == 'status/feature_testing' || github.event.label.name == 'status/feature_testing_public' }}
runs-on: ubuntu-latest
permissions: # TODO remove when public
contents: read
steps:
- uses: actions/checkout@v4
with:
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/branch-remove.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ on:
jobs:
remove:
runs-on: ubuntu-latest
permissions: # TODO remove when public
contents: read
if: ${{ (github.event.label.name == 'status/feature_testing' || github.event.label.name == 'status/feature_testing_public') || (github.event.action == 'closed' && (contains(github.event.pull_request.labels.*.name, 'status/feature_testing') || contains(github.event.pull_request.labels.*.name, 'status/feature_testing_public'))) }}
steps:
- uses: actions/checkout@v4
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/build-public-image.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ jobs:
build:
if: ${{ github.event.label.name == 'status/image_testing' }}
runs-on: ubuntu-latest
permissions: # TODO remove when public
contents: read
steps:
- uses: actions/checkout@v4
with:
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,8 @@ jobs:
analyze:
name: Analyze
runs-on: ubuntu-latest

permissions: # TODO remove when public
contents: read
strategy:
fail-fast: false
matrix:
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/cve.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,12 @@ on:
schedule:
# * is a special character in YAML so you have to quote this string
- cron: '0 8 15 * *'

jobs:
build-and-test:
runs-on: ubuntu-latest
permissions: # TODO remove when public
contents: read
steps:
- uses: actions/checkout@v4
with:
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/documentation.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,12 @@ on:
- synchronize
paths:
- '**.md'

jobs:
build-and-test:
runs-on: ubuntu-latest
permissions: # TODO remove when public
contents: read
steps:
- uses: actions/checkout@v4
with:
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/e2e-automation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,12 @@ on:
description: 'Set Qase token to enable integration'
required: false
type: string

jobs:
build-and-test:
runs-on: ubuntu-latest
permissions: # TODO remove when public
contents: read
steps:
- uses: actions/checkout@v4
with:
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/e2e-checks.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,9 @@ on:
- "kafka-ui-react-app/**"
- "kafka-ui-e2e-checks/**"
- "pom.xml"
permissions:
permissions: # TODO remove when public
statuses: write
contents: read
jobs:
build-and-test:
runs-on: ubuntu-latest
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/e2e-manual.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,12 @@ on:
description: 'Set Qase token to enable integration'
required: true
type: string

jobs:
build-and-test:
runs-on: ubuntu-latest
permissions: # TODO remove when public
contents: read
steps:
- uses: actions/checkout@v4
with:
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/e2e-weekly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ on:
jobs:
build-and-test:
runs-on: ubuntu-latest
permissions: # TODO remove when public
contents: read
steps:
- uses: actions/checkout@v4
with:
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/frontend.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,15 @@ on:
paths:
- "kafka-ui-contract/**"
- "kafka-ui-react-app/**"
permissions:
checks: write
pull-requests: write

jobs:
build-and-test:
env:
CI: true
NODE_ENV: dev
runs-on: ubuntu-latest
permissions: # TODO remove when public
contents: read
steps:
- uses: actions/checkout@v4
with:
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/master.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,12 @@ on:
workflow_dispatch:
push:
branches: [ "main" ]

jobs:
build:
runs-on: ubuntu-latest
permissions: # TODO remove when public
contents: read
steps:
- uses: actions/checkout@v4
with:
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/release-serde-api.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ on: workflow_dispatch
jobs:
release-serde-api:
runs-on: ubuntu-latest
permissions: # TODO remove when public
contents: read
steps:
- uses: actions/checkout@v4
with:
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ on:
jobs:
release:
runs-on: ubuntu-latest
permissions: # TODO remove when public
contents: read
outputs:
version: ${{steps.build.outputs.version}}
steps:
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/separate_env_public_create.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ on:
jobs:
build:
runs-on: ubuntu-latest
permissions: # TODO remove when public
contents: read
steps:
- uses: actions/checkout@v4
with:
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/workflow_linter.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,12 @@ on:
- "edited"
paths:
- ".github/workflows/**"

jobs:
build-and-test:
runs-on: ubuntu-latest
permissions: # TODO remove when public
contents: read
steps:
- uses: actions/checkout@v4
with:
Expand Down

0 comments on commit 9186cd0

Please sign in to comment.