add output
This commit is contained in:
parent
eb227db9c6
commit
2e8d064e61
3 changed files with 8 additions and 3 deletions
|
@ -30,7 +30,8 @@
|
||||||
(defn-spec terragrunt-apply! nil?
|
(defn-spec terragrunt-apply! nil?
|
||||||
[devops ::d/devops]
|
[devops ::d/devops]
|
||||||
(let [final (merge default devops)]
|
(let [final (merge default devops)]
|
||||||
(doseq [c (domain/terragrunt-apply-command final)]
|
(doseq [c (into (domain/terragrunt-apply-command final)
|
||||||
|
(domain/terragrunt-output-command final))]
|
||||||
(i/execute! c final))))
|
(i/execute! c final))))
|
||||||
|
|
||||||
(defn-spec terragrunt-destroy! nil?
|
(defn-spec terragrunt-destroy! nil?
|
||||||
|
|
|
@ -26,9 +26,13 @@
|
||||||
(defn-spec terragrunt-apply-command seq?
|
(defn-spec terragrunt-apply-command seq?
|
||||||
[devops ::devops]
|
[devops ::devops]
|
||||||
[[{:dir (d/build-path devops)} "terragrunt" "init"]
|
[[{:dir (d/build-path devops)} "terragrunt" "init"]
|
||||||
[{:dir (d/build-path devops)} "terragrunt" "apply"]])
|
[{:dir (d/build-path devops)} "terragrunt" "apply" "-auto-approve"]])
|
||||||
|
|
||||||
(defn-spec terragrunt-destroy-command seq?
|
(defn-spec terragrunt-destroy-command seq?
|
||||||
[devops ::devops]
|
[devops ::devops]
|
||||||
[[{:dir (d/build-path devops)} "terragrunt" "init"]
|
[[{:dir (d/build-path devops)} "terragrunt" "init"]
|
||||||
[{:dir (d/build-path devops)} "terragrunt" "destroy"]])
|
[{:dir (d/build-path devops)} "terragrunt" "destroy"]])
|
||||||
|
|
||||||
|
(defn-spec terragrunt-output-command seq?
|
||||||
|
[devops ::devops]
|
||||||
|
[[{:dir (d/build-path devops)} "bash" "-c" "terragrunt output -json > terraform.json"]])
|
||||||
|
|
|
@ -47,7 +47,7 @@
|
||||||
|
|
||||||
(deftest should-calculate-terragrunt-apply-command
|
(deftest should-calculate-terragrunt-apply-command
|
||||||
(is (= [[{:dir "../../../target/test/statistics"} "terragrunt" "init"]
|
(is (= [[{:dir "../../../target/test/statistics"} "terragrunt" "init"]
|
||||||
[{:dir "../../../target/test/statistics"} "terragrunt" "apply"]]
|
[{:dir "../../../target/test/statistics"} "terragrunt" "apply" "-auto-approve"]]
|
||||||
(cut/terragrunt-apply-command {:name "test"
|
(cut/terragrunt-apply-command {:name "test"
|
||||||
:module "statistics"
|
:module "statistics"
|
||||||
:project-root-path "../../.."
|
:project-root-path "../../.."
|
||||||
|
|
Loading…
Reference in a new issue