error message - Can’t access attributes on a list of objects. Did you mean to access an
│ attribute for a specific element of the list, or across all elements of the
│ list?
please advise if someone know what is this??
error message - Can’t access attributes on a list of objects. Did you mean to access an
│ attribute for a specific element of the list, or across all elements of the
│ list?
please advise if someone know what is this??
can you share what your variable sg_ingress_rule
looks like?
here it is -
variable “sg_ingress_rule” {
description = “ingress rules of security group”
type = list(object({
from_port = number
to_port = number
protocol = string
cidr_block = string
}))
default = [
{
from_port = 22
to_port = 22
protocol = "tcp"
cidr_block = "0.0.0.0/0"
}
]
}