What format does variable definition file use in Terraform?
Experience Level: Junior
Tags: Terraform
Answer
A variable definitions file uses the same basic syntax as Terraform language files, but consists only of variable name assignments.
Example:
rg_name = "myresourcegroup"
locations = [
"West Europe",
"North Europe",
]
Related Terraform job interview questions
Using Terraform CLI, how do you reformat all files to meet the standard style including the files in subfolders?
Terraform JuniorUsing Terraform CLI, how do you reformat your Terraform configuration files in the standard style?
Terraform JuniorHow can you provide variables using file to Terraform CLI without the need to specify the name of the variable definition file?
Terraform JuniorHow can you pass variables to Terraform CLI console command?
Terraform JuniorUsing Terraform CLI, how can you experiment with Terraform interpolations?
Terraform Junior