Skip to content

Commit 72ffd44

Browse files
committed
chore: destroy all
1 parent 80a6545 commit 72ffd44

1 file changed

Lines changed: 9 additions & 1 deletion

File tree

.github/workflows/destroy-deployment.yml

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,14 @@ on:
1010
options:
1111
- staging
1212
- production
13+
active_deployment:
14+
type: choice
15+
description: Which deployment is currently active (defaults to green)
16+
required: false
17+
default: green
18+
options:
19+
- blue
20+
- green
1321

1422
jobs:
1523
destroy:
@@ -74,6 +82,6 @@ jobs:
7482
cat <<< "$TERRAFORM_VARS" > tfvars.json
7583
active_deployment=$(terraform output -raw active_deployment)
7684
deployment_state=$(terraform output -raw deployment_state)
77-
terraform destroy -var-file=tfvars.json -auto-approve -var="DEPLOYMENT_STATE=$deployment_state" -var="ACTIVE_DEPLOYMENT=$active_deployment"
85+
terraform destroy -var-file=tfvars.json -auto-approve -var="DEPLOYMENT_STATE=single" -var="ACTIVE_DEPLOYMENT=green"
7886
env:
7987
TERRAFORM_VARS: ${{ vars.TERRAFORM_VARS }}

0 commit comments

Comments
 (0)