-
-
Notifications
You must be signed in to change notification settings - Fork 1
/
elb_common.tf
35 lines (32 loc) · 1.12 KB
/
elb_common.tf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
#------------------------------------------#
# Elastic Load Balancer Common Configuration
#------------------------------------------#
resource "aws_security_group" "rancher_ha_elb" {
name = "${var.name_prefix}-elb-default"
description = "Rancher HA ELB Common Traffic"
vpc_id = "${aws_vpc.rancher_ha.id}"
}
resource "aws_security_group_rule" "allow_all_self" {
type = "ingress"
from_port = 0
to_port = 0
protocol = "-1"
self = true
security_group_id = "${aws_security_group.rancher_ha_elb.id}"
}
resource "aws_security_group_rule" "allow_icmp" {
type = "ingress"
from_port = 0
to_port = 0
protocol = "icmp"
cidr_blocks = ["0.0.0.0/0"]
security_group_id = "${aws_security_group.rancher_ha_elb.id}"
}
resource "aws_security_group_rule" "allow_all_out" {
type = "egress"
from_port = 0
to_port = 0
protocol = "-1"
cidr_blocks = ["0.0.0.0/0"]
security_group_id = "${aws_security_group.rancher_ha_elb.id}"
}