Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
mamu0 committed Jun 18, 2024
1 parent fa6fdd4 commit a23212b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/infra_drift_detection.yml
Original file line number Diff line number Diff line change
Expand Up @@ -129,10 +129,10 @@ jobs:
id: plan
working-directory: ${{ steps.directory.outputs.dir }}
run: |
set +e
terraform plan -no-color -detailed-exitcode -out=plan.tfplan
PLAN_EXIT_CODE=$?
set -e
echo "Plan exit: $PLAN_EXIT_CODE"
if [ $PLAN_EXIT_CODE -eq 1 ]; then
echo "::error::Terraform plan exited with an error"
exit 1
Expand Down Expand Up @@ -175,7 +175,7 @@ jobs:
# How to configure: https://github.com/ravsamhq/notify-slack-action
# Use ${{ inputs.webhook_url }} instead of secret if you want to change it manually
- name: Drift Notification
if: ${{ always() && (env.SLACK_WEBHOOK_URL || inputs.webhook_url) }}
if: ${{ always() && (env.SLACK_WEBHOOK_URL || inputs.webhook_url) && steps.plan.outputs.drift_found == 'true' }}
uses: ravsamhq/[email protected]
with:
status: ${{ job.status }}
Expand Down

0 comments on commit a23212b

Please sign in to comment.