UPD: removed lookups
This commit is contained in:
@@ -1,8 +1,11 @@
|
||||
resource "aws_security_group" "sg" {
|
||||
count = length(var.security-groups)
|
||||
name = lookup(var.security-groups[count.index], "name")
|
||||
description = lookup(var.security-groups[count.index], "description")
|
||||
name = var.security-groups[count.index].name
|
||||
description = var.security-groups[count.index].description
|
||||
vpc_id = var.vpcid
|
||||
tags = {
|
||||
Name = var.security-groups[count.index].name
|
||||
}
|
||||
}
|
||||
|
||||
// see https://www.terraform.io/docs/configuration/functions/flatten.html
|
||||
|
||||
Reference in New Issue
Block a user