From 729e4a3b56923e504c1f425824381aba882eceeb Mon Sep 17 00:00:00 2001 From: Yauheni Batsianouski Date: Wed, 23 Sep 2020 11:00:02 +0300 Subject: [PATCH] feat: Add support for security groups ids in default sg's rules (#491) --- main.tf | 2 ++ 1 file changed, 2 insertions(+) diff --git a/main.tf b/main.tf index fd1a74952..85ba280d5 100644 --- a/main.tf +++ b/main.tf @@ -66,6 +66,7 @@ resource "aws_default_security_group" "this" { cidr_blocks = compact(split(",", lookup(ingress.value, "cidr_blocks", ""))) ipv6_cidr_blocks = compact(split(",", lookup(ingress.value, "ipv6_cidr_blocks", ""))) prefix_list_ids = compact(split(",", lookup(ingress.value, "prefix_list_ids", ""))) + security_groups = compact(split(",", lookup(ingress.value, "security_groups", ""))) description = lookup(ingress.value, "description", null) from_port = lookup(ingress.value, "from_port", 0) to_port = lookup(ingress.value, "to_port", 0) @@ -80,6 +81,7 @@ resource "aws_default_security_group" "this" { cidr_blocks = compact(split(",", lookup(egress.value, "cidr_blocks", ""))) ipv6_cidr_blocks = compact(split(",", lookup(egress.value, "ipv6_cidr_blocks", ""))) prefix_list_ids = compact(split(",", lookup(egress.value, "prefix_list_ids", ""))) + security_groups = compact(split(",", lookup(egress.value, "security_groups", ""))) description = lookup(egress.value, "description", null) from_port = lookup(egress.value, "from_port", 0) to_port = lookup(egress.value, "to_port", 0)