terraform init creates an example main.tf file in the current directory.
Exhibit:
Root module configuration:
output " vnet_id " {
value = module.my_network.vnet_id
}
Error:
Error: Reference to undeclared output value
on main.tf line 12, in output " vnet_id " :
12: value = module.my_network.vnet_id
You are using a networking module in your Terraform configuration with the name my_network. Your root module includes the configuration shown. When you run terraform validate, you get the error shown. Which option would successfully retrieve this value from your networking module?
Which two steps are required to provision new infrastructure in the Terraform workflow? Choose two correct answers.
If one of your modules uses a local value, you can expose that value to callers of the module by defining a Terraform output in the module’s configuration.