khuedoan-homelab/external/Makefile
Khue Doan 5915ebb9d1 refactor(external): just use nvim to edit tfvars
The previous setup using Ansible is kinda unessesary since it just
edit the same tfvars file.
2024-01-20 11:48:25 +07:00

24 lines
419 B
Makefile

.POSIX:
default: apply
~/.terraform.d/credentials.tfrc.json:
terraform login
terraform.tfvars:
cp terraform.tfvars.example ${@}
nvim ${@}
.terraform.lock.hcl: ~/.terraform.d/credentials.tfrc.json versions.tf terraform.tfvars
terraform init
touch ${@}
namespaces:
ansible-playbook namespaces.yml
plan: .terraform.lock.hcl
terraform plan
apply: .terraform.lock.hcl namespaces
terraform apply -auto-approve