Improve makefile targets consistency

This commit is contained in:
Khue Doan 2021-05-23 12:24:32 +07:00
parent 00a8d044c0
commit 6e39a3db19
3 changed files with 15 additions and 6 deletions

View File

@ -1,11 +1,17 @@
.POSIX: .POSIX:
default: run default: apply
.PHONY: run .PHONY: metal
run: metal:
make -C metal make -C metal
.PHONY: infra
infra:
make -C infra make -C infra
.PHONY: apps
apps:
make -C apps make -C apps
.PHONY: tools .PHONY: tools
@ -15,3 +21,6 @@ tools:
.PHONY: docs .PHONY: docs
docs: docs:
make -C docs make -C docs
.PHONY: apply
apply: metal infra apps

View File

@ -8,5 +8,5 @@ default: apply
apply: apply:
kubectl apply --kustomize . kubectl apply --kustomize .
delete: destroy:
kubectl delete --kustomize . kubectl delete --kustomize .

View File

@ -3,7 +3,7 @@
TF_IN_AUTOMATION = true TF_IN_AUTOMATION = true
default: init plan apply default: init apply
init: init:
terraform init -input=false terraform init -input=false
@ -11,7 +11,7 @@ init:
plan: plan:
terraform plan -input=false -out=/tmp/tfplan terraform plan -input=false -out=/tmp/tfplan
apply: apply: plan
terraform apply -input=false /tmp/tfplan terraform apply -input=false /tmp/tfplan
destroy: destroy: