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.
This commit is contained in:
Michael Li authored and GitHub committed 2023-02-23 11:58:43 -05:00
1 parent c309f46568
commit 7733677e34
1 file changed
+1 -1
+1 -1
View File
@@ -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