Skip to content

Commit e08a220

Browse files
marwan37strickvl
andcommitted
Remove cleanup steps from AWS Modular workflow
Following @strickvl's suggestion, removed the terraform destroy and related cleanup commands. These steps are unnecessary for our ephemeral instances and do not impact the repo's state. Co-authored-by: Alex Strick van Linschoten <strickvl@users.noreply.github.com>
1 parent 106c6b3 commit e08a220

File tree

1 file changed

+5
-40
lines changed

1 file changed

+5
-40
lines changed

.github/workflows/aws-integration-test.yml

Lines changed: 5 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,9 @@ jobs:
2424
uses: actions/checkout@v4.1.1
2525

2626
- name: Setup Terraform
27-
uses: hashicorp/setup-terraform@v2
27+
uses: hashicorp/setup-terraform@v3.0.0
2828
with:
29-
terraform_version: 1.3.4
29+
terraform_version: 1.6.0
3030

3131
- name: Copy Override File
3232
run: |
@@ -60,24 +60,6 @@ jobs:
6060
../../../../tests/integration/aws-modular/verify_stack.sh "$ABSOLUTE_PATH"
6161
working-directory: src/mlstacks/terraform/aws-modular
6262

63-
- name: Cleanup Resources for aws-modular
64-
run: |
65-
cd src/mlstacks/terraform/aws-modular
66-
terraform destroy -auto-approve -var-file="../../../../tests/integration/aws-modular/local.tfvars"
67-
rm -rf .terraform
68-
rm -rf volume
69-
rm -f .terraform.lock.hcl
70-
rm -f terraform.tfstate
71-
rm -f terraform.tfstate.backup
72-
rm -f localstack_providers_override.tf
73-
rm -f aws_modular_stack_*.yaml
74-
75-
- name: Ensure _override.tf Deletion
76-
if: always()
77-
run: |
78-
rm -f src/mlstacks/terraform/aws-modular/_override.tf
79-
working-directory: ${{ github.workspace }}
80-
8163
aws_remote_state_integration_test:
8264
name: aws_remote_state_integration_test
8365
runs-on: ubuntu-latest
@@ -94,12 +76,12 @@ jobs:
9476
AWS_SECRET_ACCESS_KEY: test
9577
steps:
9678
- name: Checkout Repository
97-
uses: actions/checkout@v2
79+
uses: actions/checkout@v4.1.1
9880

9981
- name: Setup Terraform
100-
uses: hashicorp/setup-terraform@v2
82+
uses: hashicorp/setup-terraform@v3.0.0
10183
with:
102-
terraform_version: 1.3.4
84+
terraform_version: 1.6.0
10385

10486
- name: Copy Override File
10587
run: |
@@ -119,20 +101,3 @@ jobs:
119101
AWS_ACCESS_KEY_ID: test
120102
AWS_SECRET_ACCESS_KEY: test
121103
AWS_DEFAULT_REGION: eu-north-1
122-
123-
- name: Cleanup Resources for aws-remote-state
124-
run: |
125-
cd src/mlstacks/terraform/aws-remote-state
126-
terraform destroy -auto-approve -var-file="../../../../tests/integration/aws-remote-state/local.tfvars"
127-
rm -rf .terraform
128-
rm -rf volume
129-
rm -f .terraform.lock.hcl
130-
rm -f terraform.tfstate
131-
rm -f terraform.tfstate.backup
132-
rm -f localstack_providers_override.tf
133-
134-
- name: Ensure _override.tf Deletion
135-
if: always()
136-
run: |
137-
rm -f src/mlstacks/terraform/aws-remote-state/_override.tf
138-
working-directory: ${{ github.workspace }}

0 commit comments

Comments
 (0)