terraform/examples/aws-rds/sg.tf

24 lines
415 B
Terraform
Raw Normal View History

2015-06-09 17:02:19 +02:00
resource "aws_security_group" "default" {
name = "main_rds_sg"
description = "Allow all inbound traffic"
2015-06-09 18:37:22 +02:00
vpc_id = "${var.vpc_id}"
2015-06-09 17:02:19 +02:00
ingress {
from_port = 0
to_port = 65535
protocol = "TCP"
cidr_blocks = ["${var.cidr_blocks}"]
}
egress {
from_port = 0
to_port = 0
protocol = "-1"
2015-06-09 18:37:22 +02:00
cidr_blocks = ["0.0.0.0/0"]
2015-06-09 17:02:19 +02:00
}
tags {
Name = "${var.sg_name}"
}
}