Hi
My terraform plan showing below error, variable is declared and being passed still getting error
var.iexams_vpcpeers
Map of vpc peerings used for indirect reference by iexams_networks.
Enter a value:
Error: Invalid expression
on line 1:
(source code not available)
Expected the start of an expression, but found an invalid expression token.
Error: No value for required variable
on variables.tf line 121:
121: variable “iexams_vpcpeers” {
The root module input variable “iexams_vpcpeers” is not set, and has no
default value. Use a -var or -var-file command line argument to provide a
value for this variable.
Below is my .tfvar
iexams_vpcpeers = {
mgmt_idmz = “pcx-030541d86633eb85a”
eapp_iegress = “pcx-088b39c21a265f858”
iegressnp_eapp = “pcx-0a40e06e33abc5499”
iegressnp_mgmt = “pcx-08872d1da3dfdff87”
eapp_aapp = “pcx-04c0d31d6c020f030”
aapp_mgmt = “pcx-00c78866a58c47b52”
mgmt_eapp = “pcx-01a2855519c73a6ac”
mgmt_mgmt2 = “pcx-0344a8b2ceb04e258”
mgmt_bastion = “pcx-0b2cf3985e9734f60”
bastion_idmz = “pcx-06aedb3a022827e8c”
bastion_aapp = “pcx-04c57ce99d29f6ec2”
bastion_eapp = “pcx-08bd50934c787ef37”
iexams_uat_mims = “pcx-09a55804da32c757c”
}
Var.tf
variable “iexams_vpcpeers” {
type = map(any)
description = “Map of vpc peerings used for indirect reference by iexams_networks.”
}
Can help what could be the issue