From cd0d6310a67ad16dddbfe6555078cd112f06f3e2 Mon Sep 17 00:00:00 2001 From: geloman Date: Wed, 20 Nov 2024 00:54:14 +0800 Subject: [PATCH] ci: update terraform destroy workflow file --- .github/workflows/terraform-destroy.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/terraform-destroy.yaml b/.github/workflows/terraform-destroy.yaml index b7afdf5..1b238a4 100644 --- a/.github/workflows/terraform-destroy.yaml +++ b/.github/workflows/terraform-destroy.yaml @@ -24,10 +24,10 @@ jobs: - name: Terraform Validate run: terraform validate - - run: echo "DROPLET_SIZE=$(terraform output -raw droplet_size)" >> $GITHUB_ENV + - run: echo "DROPLET_SIZE=$(terraform output -json | jq -r '.droplet_size.value // empty')" >> $GITHUB_ENV - name: Terraform Destroy run: terraform destroy -auto-approve env: DIGITALOCEAN_TOKEN: ${{ secrets.DIGITALOCEAN_TOKEN }} - TF_VAR_droplet_size: $DROPLET_SIZE + TF_VAR_droplet_size: ${{ env.DROPLET_SIZE }}