mirror of
https://github.com/coder/coder.git
synced 2026-10-29 17:44:33 +08:00
chore: update workflow permissions (#15349)
This commit is contained in:
@@ -9,16 +9,7 @@ on:
|
|||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
|
|
||||||
permissions:
|
permissions:
|
||||||
actions: none
|
|
||||||
checks: none
|
|
||||||
contents: read
|
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
|
# Cancel in-progress runs for pull requests when developers push
|
||||||
# additional changes
|
# additional changes
|
||||||
@@ -821,6 +812,8 @@ jobs:
|
|||||||
needs: changes
|
needs: changes
|
||||||
if: github.ref == 'refs/heads/main' && needs.changes.outputs.docs-only == 'false' && !github.event.pull_request.head.repo.fork
|
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' }}
|
runs-on: ${{ github.repository_owner == 'coder' && 'depot-ubuntu-22.04-8' || 'ubuntu-latest' }}
|
||||||
|
permissions:
|
||||||
|
packages: write # Needed to push images to ghcr.io
|
||||||
env:
|
env:
|
||||||
DOCKER_CLI_EXPERIMENTAL: "enabled"
|
DOCKER_CLI_EXPERIMENTAL: "enabled"
|
||||||
outputs:
|
outputs:
|
||||||
|
|||||||
@@ -16,6 +16,9 @@ on:
|
|||||||
# For jobs that don't run on draft PRs.
|
# For jobs that don't run on draft PRs.
|
||||||
- ready_for_review
|
- ready_for_review
|
||||||
|
|
||||||
|
permissions:
|
||||||
|
contents: read
|
||||||
|
|
||||||
# Only run one instance per PR to ensure in-order execution.
|
# Only run one instance per PR to ensure in-order execution.
|
||||||
concurrency: pr-${{ github.ref }}
|
concurrency: pr-${{ github.ref }}
|
||||||
|
|
||||||
|
|||||||
@@ -8,6 +8,9 @@ on:
|
|||||||
description: "PR number"
|
description: "PR number"
|
||||||
required: true
|
required: true
|
||||||
|
|
||||||
|
permissions:
|
||||||
|
contents: read
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
cleanup:
|
cleanup:
|
||||||
runs-on: "ubuntu-latest"
|
runs-on: "ubuntu-latest"
|
||||||
|
|||||||
Reference in New Issue
Block a user