From 9a42d684fb5218804cc72cdf26b52dc0be843e83 Mon Sep 17 00:00:00 2001 From: Amruth Pillai Date: Wed, 23 Nov 2022 14:15:36 +0100 Subject: [PATCH] add branching deploy condition --- .github/workflows/digitalocean-deploy.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/digitalocean-deploy.yml b/.github/workflows/digitalocean-deploy.yml index e07b8248..8760a3ee 100644 --- a/.github/workflows/digitalocean-deploy.yml +++ b/.github/workflows/digitalocean-deploy.yml @@ -10,6 +10,7 @@ on: jobs: on-success: runs-on: ubuntu-latest + if: ${{ github.event.workflow_run.conclusion == 'success' }} steps: - name: Install DigitalOcean CLI uses: digitalocean/action-doctl@v2.2.0 @@ -21,6 +22,7 @@ jobs: on-failure: runs-on: ubuntu-latest + if: ${{ github.event.workflow_run.conclusion == 'failure' }} steps: - name: Abruptly end the worklfow run: exit 1