X-Git-Url: https://gerrit.fd.io/r/gitweb?a=blobdiff_plain;f=resources%2Flibraries%2Fbash%2Ffunction%2Fcommon.sh;h=44a897ed2b5c6b1a4f965a231c827d538f82a028;hb=refs%2Fchanges%2F01%2F39001%2F1;hp=d768e9b66c86d97a52d6215b75826e17fd15eea1;hpb=fbab829993ab88325def28029ea627a1613c09de;p=csit.git diff --git a/resources/libraries/bash/function/common.sh b/resources/libraries/bash/function/common.sh index d768e9b66c..44a897ed2b 100644 --- a/resources/libraries/bash/function/common.sh +++ b/resources/libraries/bash/function/common.sh @@ -656,7 +656,7 @@ function prepare_topology () { export TF_VAR_testbed_name="${TEST_CODE}" TERRAFORM_MODULE_DIR="terraform-aws-${NODENESS}-${FLAVOR}-c5n" terraform_init || die "Failed to call terraform init." - trap 'terraform_destroy' ERR || { + trap "terraform_destroy" ERR EXIT || { die "Trap attempt failed, please cleanup manually. Aborting!" } terraform_apply || die "Failed to call terraform apply."