From fd4f7f5be0a05882027db88ec41a2f1f72de05b0 Mon Sep 17 00:00:00 2001 From: Josh Furie Date: Sat, 20 Jul 2024 12:38:58 -0700 Subject: [PATCH] fix: Update deployment status for develop environment --- .github/workflows/develop.deploy-functions.yml | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/.github/workflows/develop.deploy-functions.yml b/.github/workflows/develop.deploy-functions.yml index a355ee698..a03c79289 100644 --- a/.github/workflows/develop.deploy-functions.yml +++ b/.github/workflows/develop.deploy-functions.yml @@ -51,7 +51,7 @@ jobs: with: token: '${{ secrets.GH_TOKEN}}' environment-url: http://my-app-url.com - environment: production + environment: develop - name: Authenticate with Google Cloud if: steps.semantic.outputs.new_release_published == 'true' id: auth @@ -82,3 +82,19 @@ jobs: - name: 'Use output' run: 'curl "${{ steps.deploy.outputs.url }}"' + + - name: Update deployment status (success) + if: success() + uses: chrnorm/deployment-status@v2 + with: + token: '${{ secrets.GH_TOKEN }}' + environment-url: ${{steps.deploy.outputs.url}} + state: 'success' + deployment-id: ${{ steps.deployment.outputs.deployment_id }} + - name: Update deployment status (failure) + if: failure() + uses: chrnorm/deployment-status@v2 + with: + token: '${{ secrets.GH_TOKEN}}' + state: 'failure' + deployment-id: ${{ steps.deployment.outputs.deployment_id }}