|
@@ -47,6 +47,16 @@ resource "aws_security_group_rule" "ghe_server_inbound_https_internal_elb_23" {
|
|
|
description = "Inbound tcp/23 from internal ELBs"
|
|
|
}
|
|
|
|
|
|
+resource "aws_security_group_rule" "ghe_server_inbound_external_elb_80" {
|
|
|
+ security_group_id = aws_security_group.ghe_server.id
|
|
|
+ source_security_group_id = aws_security_group.ghe_elb_external.id
|
|
|
+ type = "ingress"
|
|
|
+ from_port = 80
|
|
|
+ to_port = 80
|
|
|
+ protocol = "tcp"
|
|
|
+ description = "Inbound HTTP from external ELBs for LetsEncrypt"
|
|
|
+}
|
|
|
+
|
|
|
resource "aws_security_group_rule" "ghe_server_inbound_mgmt_ssh_cidr" {
|
|
|
security_group_id = aws_security_group.ghe_server.id
|
|
|
type = "ingress"
|
|
@@ -158,8 +168,28 @@ resource "aws_security_group_rule" "ghe_server_inbound_https_external_elb_8444"
|
|
|
}
|
|
|
|
|
|
#-----------------------------------------------------------------
|
|
|
-# Inbound access
|
|
|
+# Outbound access
|
|
|
#-----------------------------------------------------------------
|
|
|
+resource "aws_security_group_rule" "ghe_server_outbound_http" {
|
|
|
+ security_group_id = aws_security_group.ghe_server.id
|
|
|
+ type = "egress"
|
|
|
+ cidr_blocks = [ "0.0.0.0/0" ]
|
|
|
+ from_port = 80
|
|
|
+ to_port = 80
|
|
|
+ protocol = "tcp"
|
|
|
+ description = "Outbound http for letsencrypt"
|
|
|
+}
|
|
|
+
|
|
|
+resource "aws_security_group_rule" "ghe_server_outbound_https" {
|
|
|
+ security_group_id = aws_security_group.ghe_server.id
|
|
|
+ type = "egress"
|
|
|
+ cidr_blocks = [ "0.0.0.0/0" ]
|
|
|
+ from_port = 443
|
|
|
+ to_port = 443
|
|
|
+ protocol = "tcp"
|
|
|
+ description = "Outbound https for letsencrypt"
|
|
|
+}
|
|
|
+
|
|
|
resource "aws_security_group_rule" "ghe_server_outbound_syslog" {
|
|
|
security_group_id = aws_security_group.ghe_server.id
|
|
|
type = "egress"
|
|
@@ -169,3 +199,5 @@ resource "aws_security_group_rule" "ghe_server_outbound_syslog" {
|
|
|
protocol = "tcp"
|
|
|
description = "Outbound syslog"
|
|
|
}
|
|
|
+
|
|
|
+
|