From 6788d98d9d00197d5cb674dad036d262eecf20c8 Mon Sep 17 00:00:00 2001 From: pheiduck <47042125+pheiduck@users.noreply.github.com> Date: Sun, 4 Feb 2024 22:54:34 +0100 Subject: [PATCH] CI: restrict workflows to only run on owner repository --- .github/workflows/codeql.yml | 1 + .github/workflows/deploy-development.yml | 1 + .github/workflows/deploy-nightly.yml | 1 + .github/workflows/deploy.yml | 1 + .github/workflows/lint.yml | 1 + .github/workflows/npm-update-bot.yml | 1 + .github/workflows/stale.yml | 1 + 7 files changed, 7 insertions(+) diff --git a/.github/workflows/codeql.yml b/.github/workflows/codeql.yml index 7c32933..31d962d 100644 --- a/.github/workflows/codeql.yml +++ b/.github/workflows/codeql.yml @@ -12,6 +12,7 @@ jobs: analyze: name: Analyze runs-on: ubuntu-latest + if: github.repository_owner == 'wg-easy' permissions: actions: read contents: read diff --git a/.github/workflows/deploy-development.yml b/.github/workflows/deploy-development.yml index 81707dc..fa912f7 100644 --- a/.github/workflows/deploy-development.yml +++ b/.github/workflows/deploy-development.yml @@ -7,6 +7,7 @@ jobs: deploy: name: Build & Deploy runs-on: ubuntu-latest + if: github.repository_owner == 'wg-easy' permissions: packages: write contents: read diff --git a/.github/workflows/deploy-nightly.yml b/.github/workflows/deploy-nightly.yml index ae0d978..05d033c 100644 --- a/.github/workflows/deploy-nightly.yml +++ b/.github/workflows/deploy-nightly.yml @@ -9,6 +9,7 @@ jobs: deploy: name: Build & Deploy runs-on: ubuntu-latest + if: github.repository_owner == 'wg-easy' permissions: packages: write contents: read diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 84e5b17..332b3a7 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -10,6 +10,7 @@ jobs: deploy: name: Build & Deploy runs-on: ubuntu-latest + if: github.repository_owner == 'wg-easy' permissions: packages: write contents: read diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index cf444d2..088710a 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -11,6 +11,7 @@ jobs: lint: name: Lint runs-on: ubuntu-latest + if: github.repository_owner == 'wg-easy' steps: - name: Checkout repository uses: actions/checkout@v4 diff --git a/.github/workflows/npm-update-bot.yml b/.github/workflows/npm-update-bot.yml index 03af94b..41ddfe3 100644 --- a/.github/workflows/npm-update-bot.yml +++ b/.github/workflows/npm-update-bot.yml @@ -10,6 +10,7 @@ jobs: npmupbot: name: NPM Update Bot 🤖 runs-on: ubuntu-latest + if: github.repository_owner == 'wg-easy' steps: - name: Checkout repository uses: actions/checkout@v4 diff --git a/.github/workflows/stale.yml b/.github/workflows/stale.yml index 9131457..868fa29 100644 --- a/.github/workflows/stale.yml +++ b/.github/workflows/stale.yml @@ -14,6 +14,7 @@ jobs: stale: runs-on: ubuntu-latest + if: github.repository_owner == 'wg-easy' permissions: issues: write pull-requests: write