Oracle Cloud Infrastructure 2019 Developer Associate — Question 117

Which does NOT set a variable in Terraform?

Answer options

Correct answer: A

Explanation

Option A is the correct answer because passing a variable with a var statement does not actually set the variable; it is used to reference variables that have already been defined. The other options describe valid methods for setting variables in Terraform, such as through key value pairs in files, default values in declarations, and environment variables with the TF_VAR_ prefix.