diff --git a/.github/workflows/e2e.yaml b/.github/workflows/e2e.yaml index 8ed231a6..7021afef 100644 --- a/.github/workflows/e2e.yaml +++ b/.github/workflows/e2e.yaml @@ -36,6 +36,12 @@ jobs: uses: actions/checkout@v3 with: fetch-depth: 0 + - name: Configure AWS Credentials + uses: aws-actions/configure-aws-credentials@v4 + with: + aws-region: eu-west-1 + role-to-assume: arn:aws:iam::911167907168:oidc-provider/token.actions.githubusercontent.com + role-session-name: GitHub_to_AWS_via_FederatedOIDC - name: Store test timestamp run: echo "TIMESTAMP=$(date +'%s')" >> $GITHUB_ENV - name: Setup test repository SSH key diff --git a/nuke-config.yml b/nuke-config.yml index a522bf46..8d31db57 100644 --- a/nuke-config.yml +++ b/nuke-config.yml @@ -10,6 +10,8 @@ accounts: IAMRole: - property: Name value: "OrganizationAccountAccessRole" + - property: Name + value: "admin" IAMRolePolicyAttachment: - property: RoleName value: "OrganizationAccountAccessRole" diff --git a/test/plural/lib/aws-teardown.yaml b/test/plural/lib/aws-teardown.yaml index 69d93c86..6bab4d0f 100644 --- a/test/plural/lib/aws-teardown.yaml +++ b/test/plural/lib/aws-teardown.yaml @@ -2,8 +2,9 @@ executor: aws-teardown input: resourceGroup: '' steps: - - script: aws-nuke run --config ../../nuke-config.yml --force --access-key-id $AWS_ACCESS_KEY_ID --secret-access-key $AWS_SECRET_ACCESS_KEY --no-dry-run - retry: 3 + - script: aws-nuke run --config ../../nuke-config.yml --force --access-key-id $AWS_ACCESS_KEY_ID --secret-access-key $AWS_SECRET_ACCESS_KEY --no-dry-run --no-alias-check --max-wait-retries 100 + retry: 5 + timeout: 1800 retry_if: - result.code ShouldNotEqual 0 delay: 5 \ No newline at end of file