From 31b210953dce5c8017a409347119e67438d70f72 Mon Sep 17 00:00:00 2001 From: Taimoor Ahmad Date: Tue, 23 Jan 2024 11:29:34 -0500 Subject: [PATCH] add task hard (#189) --- Taskfile.yml | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/Taskfile.yml b/Taskfile.yml index f4ccc26a..882328e1 100644 --- a/Taskfile.yml +++ b/Taskfile.yml @@ -61,6 +61,30 @@ tasks: - task: go:fix - task: format-fix + hard-apply: + desc: Rebuild and run "terraform apply -auto-approve" + cmds: + - task: build + - task: init + - task: terraform-command + vars: { TF_COMMAND: "apply -auto-approve", TF_CMD_DIR: "{{.WORKSPACE_DIR}}" } + + hard-destroy: + desc: Rebuild and run "terraform destroy -auto-approve" + cmds: + - task: build + - task: init + - task: terraform-command + vars: { TF_COMMAND: "destroy -auto-approve", TF_CMD_DIR: "{{.WORKSPACE_DIR}}" } + + hard-plan: + desc: Rebuild and run "terraform plan" + cmds: + - task: build + - task: init + - task: terraform-command + vars: { TF_COMMAND: "plan", TF_CMD_DIR: "{{.WORKSPACE_DIR}}" } + init: desc: Initialize terraform workspace dir: "{{.WORKSPACE_DIR}}"