From 8b5b3701da192f70509e0be975308577ff952660 Mon Sep 17 00:00:00 2001 From: Ellie Bahadori Date: Wed, 2 Sep 2020 09:44:18 -0700 Subject: [PATCH] Prevent builds from running on forks Resolves gh-1678 --- .github/workflows/continuous-integration-workflow.yml | 3 +++ .github/workflows/pr-build-workflow.yml | 1 + 2 files changed, 4 insertions(+) diff --git a/.github/workflows/continuous-integration-workflow.yml b/.github/workflows/continuous-integration-workflow.yml index 79345390..5502bb87 100644 --- a/.github/workflows/continuous-integration-workflow.yml +++ b/.github/workflows/continuous-integration-workflow.yml @@ -19,6 +19,7 @@ jobs: build: name: Build runs-on: ubuntu-latest + if: github.repository == 'spring-projects/spring-session' strategy: matrix: jdk: [8, 11] @@ -48,6 +49,7 @@ jobs: name: Deploy Artifacts needs: [build] runs-on: ubuntu-latest + if: github.repository == 'spring-projects/spring-session' steps: - uses: actions/checkout@v2 - name: Set up JDK @@ -76,6 +78,7 @@ jobs: name: Deploy Docs needs: [build] runs-on: ubuntu-latest + if: github.repository == 'spring-projects/spring-session' steps: - uses: actions/checkout@v2 - name: Set up JDK diff --git a/.github/workflows/pr-build-workflow.yml b/.github/workflows/pr-build-workflow.yml index 8f84bb88..4bf8d1b8 100644 --- a/.github/workflows/pr-build-workflow.yml +++ b/.github/workflows/pr-build-workflow.yml @@ -6,6 +6,7 @@ jobs: build: name: Build runs-on: ubuntu-latest + if: github.repository == 'spring-projects/spring-session' strategy: matrix: jdk: [8, 11]