Ask Your Question
3

Does Terraform disregard values contained in .tfvars files?

asked 2023-06-15 08:34:22 +0000

devzero gravatar image

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
3

answered 2023-06-15 09:01:02 +0000

scrum gravatar image

No, Terraform uses .tfvars files to read and assign variable values to the corresponding variables in the Terraform code. If a variable is defined in both the .tfvars file and the Terraform code, the .tfvars value will take precedence. However, if a variable is not defined in the .tfvars file, Terraform will use the default value in the code or prompt the user to enter a value during runtime if no default is set.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account. This space is reserved only for answers. If you would like to engage in a discussion, please instead post a comment under the question or an answer that you would like to discuss

Add Answer


Question Tools

Stats

Asked: 2023-06-15 08:34:22 +0000

Seen: 18 times

Last updated: Jun 15 '23