Skip to content

chore: update workflow permissions #15349

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Nov 4, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 2 additions & 9 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,16 +9,7 @@ on:
workflow_dispatch:

permissions:
actions: none
checks: none
contents: read
deployments: none
issues: none
packages: write
pull-requests: none
repository-projects: none
security-events: none
statuses: none

# Cancel in-progress runs for pull requests when developers push
# additional changes
Expand Down Expand Up @@ -821,6 +812,8 @@ jobs:
needs: changes
if: github.ref == 'refs/heads/main' && needs.changes.outputs.docs-only == 'false' && !github.event.pull_request.head.repo.fork
runs-on: ${{ github.repository_owner == 'coder' && 'depot-ubuntu-22.04-8' || 'ubuntu-latest' }}
permissions:
packages: write # Needed to push images to ghcr.io
env:
DOCKER_CLI_EXPERIMENTAL: "enabled"
outputs:
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/contrib.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ on:
# For jobs that don't run on draft PRs.
- ready_for_review

permissions:
contents: read

# Only run one instance per PR to ensure in-order execution.
concurrency: pr-${{ github.ref }}

Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/pr-cleanup.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@ on:
description: "PR number"
required: true

permissions:
contents: read

jobs:
cleanup:
runs-on: "ubuntu-latest"
Expand Down
Loading