Skip to content

Commit

Permalink
Merge pull request #31284 from def-/pr-terraform-noise
Browse files Browse the repository at this point in the history
ci: Force-destroy terraform only in terraform tests
  • Loading branch information
def- authored Feb 4, 2025
2 parents 01fc498 + 8be6efb commit ef6c21a
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions ci/plugins/mzcompose/hooks/pre-exit
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,8 @@ run kill || true
run rm --force -v
run down --volumes

ci_unimportant_heading "terraform: Destroying leftover state in case job was cancelled or timed out..."
bin/ci-builder run stable terraform -chdir=test/terraform/aws destroy || true
bin/ci-builder run stable terraform -chdir=test/terraform/gcp destroy || true
if [[ "$BUILDKITE_LABEL" =~ Terraform\ .* ]]; then
ci_unimportant_heading "terraform: Destroying leftover state in case job was cancelled or timed out..."
bin/ci-builder run stable terraform -chdir=test/terraform/aws destroy || true
bin/ci-builder run stable terraform -chdir=test/terraform/gcp destroy || true
fi

0 comments on commit ef6c21a

Please sign in to comment.