From 7733677e344123f039c2a5ac6e547e1b8c80e1d3 Mon Sep 17 00:00:00 2001 From: Michael Li Date: Thu, 23 Feb 2023 11:58:43 -0500 Subject: [PATCH] chore(enos): Modify destroy condition (#3001) Sometimes, the workflow can fail before enos is even installed, which causes this step to fail due enos not existing. This change makes it such that this step only runs if the Retry step fails. --- .github/workflows/enos-run.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/enos-run.yml b/.github/workflows/enos-run.yml index ce2d72312..1b42bb63b 100644 --- a/.github/workflows/enos-run.yml +++ b/.github/workflows/enos-run.yml @@ -170,7 +170,7 @@ jobs: export ENOS_VAR_enos_user=$GITHUB_ACTOR && \ enos scenario run --timeout 60m0s --chdir ./enos ${{ matrix.filter }} - name: Destroy Enos scenario - if: ${{ always() }} + if: ${{ always() && steps.run_retry.outcome == 'failure' }} env: ENOS_VAR_aws_region: us-east-1 ENOS_VAR_aws_ssh_keypair_name: ${{ github.event.repository.name }}-ci-ssh-key