Skip to content

Commit 8fc5ddc

Browse files
committed
add rules for ipv6
1 parent c110fca commit 8fc5ddc

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

elb/lab-setup.ps1

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,12 +64,25 @@ $appsg = New-EC2SecurityGroup -VpcId $vpc.VpcId -GroupName "app-sg" -GroupDescri
6464
$dbsg = New-EC2SecurityGroup -VpcId $vpc.VpcId -GroupName "db-sg" -GroupDescription "db-sg"
6565

6666
#Create IPpermissions for public http and https
67+
68+
$httpip = new-object Amazon.EC2.Model.IpPermission
69+
$httpip.IpProtocol = "tcp"
70+
$httpip.FromPort = 80
71+
$httpip.ToPort = 80
72+
$httpip.IpRanges.Add("::0/0")
73+
6774
$httpip = new-object Amazon.EC2.Model.IpPermission
6875
$httpip.IpProtocol = "tcp"
6976
$httpip.FromPort = 80
7077
$httpip.ToPort = 80
7178
$httpip.IpRanges.Add("0.0.0.0/0")
7279

80+
$httpsip = new-object Amazon.EC2.Model.IpPermission
81+
$httpsip.IpProtocol = "tcp"
82+
$httpsip.FromPort = 443
83+
$httpsip.ToPort = 443
84+
$httpsip.IpRanges.Add("::0/0")
85+
7386
$httpsip = new-object Amazon.EC2.Model.IpPermission
7487
$httpsip.IpProtocol = "tcp"
7588
$httpsip.FromPort = 443

0 commit comments

Comments
 (0)