Terraform variable using TF_VAR environment variables example

How to set Terraform Variables in Windows?


Terraform will read environment variables in the form of TF_VAR_name to find the value for a variable. For example, the TF_VAR_region variable can be set to set the region variable.

  • Command to set ENV var in Linux: export TF_VAR_reponame
  • Command to set ENV var in Windows: set TF_VAR_reponame
Rajesh Kumar
Follow me