2015-06-09 10:02:19 -05:00
|
|
|
resource "aws_security_group" "default" {
|
2016-09-22 06:49:09 -05:00
|
|
|
name = "main_rds_sg"
|
2015-06-09 10:02:19 -05:00
|
|
|
description = "Allow all inbound traffic"
|
2016-09-22 06:49:09 -05:00
|
|
|
vpc_id = "${var.vpc_id}"
|
2015-06-09 10:02:19 -05:00
|
|
|
|
|
|
|
ingress {
|
2016-09-22 06:49:09 -05:00
|
|
|
from_port = 0
|
|
|
|
to_port = 65535
|
|
|
|
protocol = "TCP"
|
2015-08-31 03:19:02 -05:00
|
|
|
cidr_blocks = ["${var.cidr_blocks}"]
|
2015-06-09 10:02:19 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
egress {
|
2016-09-22 06:49:09 -05:00
|
|
|
from_port = 0
|
|
|
|
to_port = 0
|
|
|
|
protocol = "-1"
|
2015-08-31 03:19:02 -05:00
|
|
|
cidr_blocks = ["0.0.0.0/0"]
|
2015-06-09 10:02:19 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
tags {
|
|
|
|
Name = "${var.sg_name}"
|
|
|
|
}
|
|
|
|
}
|