Skip to content

Commit

Permalink
use deployment-checks step
Browse files Browse the repository at this point in the history
  • Loading branch information
GrantBirki committed Mar 4, 2024
1 parent 735da67 commit 1259450
Showing 1 changed file with 16 additions and 1 deletion.
17 changes: 16 additions & 1 deletion .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,23 @@ env:
WORKING_DIR: "terraform/"

jobs:
deployment-check:
runs-on: ubuntu-latest
outputs: # set outputs for use in downstream jobs
continue: ${{ steps.deployment-check.outputs.continue }}

steps:
# https://github.com/github/branch-deploy/blob/d3c24bd92505e623615b75ffdfac5ed5259adbdb/docs/merge-commit-strategy.md
- name: deployment check
uses: github/branch-deploy@v9
id: deployment-check
with:
merge_deploy_mode: "true"
environment: production

deploy:
if: github.event_name == 'push'
if: ${{ needs.deployment-check.outputs.continue == 'true' && github.event_name == 'push' }}
needs: deployment-check
environment: production
runs-on: ubuntu-latest
defaults:
Expand Down

0 comments on commit 1259450

Please sign in to comment.