Re-pull repo to get most up-to-date notes
main.tf = where your code lives for provisioning infastructure
variables.tf = where you declare variables
terraform.tfvars = where you set values for your declared variables
##Comamands
-
terraform init
- Downloads the provider.
- creates .terraform.lock.hcl
- This locks the version.
- Creates a hidden .terraform directory.
-
terraform fmt
- Ensures goo, consistent formatting.
-
terraform validate
- Verifies syntax is correct and the code is internally consistent.
-
terraform plan
- Shows you what will happen when you run and apply your changes.
-
terraform apply
- Runs a terraform plan.
- Confirms you want to continue with a yes.
- Applies the changes .
-
terraform show
- shows current state (state is an important concept to understand LINK TO STATE INFO).
-
terraform state list
- Lists the state files.
-
terraform state show
- Shows state for a specific .