Skip to content
This repository has been archived by the owner on Apr 27, 2020. It is now read-only.

Commit

Permalink
removing multi rule creation
Browse files Browse the repository at this point in the history
  • Loading branch information
Fahad Tariq committed Aug 29, 2019
1 parent b7beb87 commit d50584e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions cluster.tf
Original file line number Diff line number Diff line change
Expand Up @@ -82,11 +82,11 @@ resource "aws_security_group_rule" "additional_sg_ingress" {
}

resource "aws_security_group_rule" "additional_ip_ingress" {
count = length(var.cluster_access_additional_ip)
count = length(var.cluster_access_additional_ip)>0 ? 1 : 0
security_group_id = aws_security_group.cluster.id
type = "ingress"
from_port = 443
to_port = 443
protocol = "tcp"
cidr_blocks = var.cluster_access_additional_ip[count.index]
cidr_blocks = var.cluster_access_additional_ip
}

0 comments on commit d50584e

Please sign in to comment.