From 40959a7ffc9078df24c67fe3552bcfcc10cf2044 Mon Sep 17 00:00:00 2001 From: George Taylor Date: Fri, 6 Oct 2023 19:50:01 +0100 Subject: [PATCH 1/3] alb to weblogic rule --- .../environment_all_components/weblogic_service.tf | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/terraform/environments/delius-core/modules/environment_all_components/weblogic_service.tf b/terraform/environments/delius-core/modules/environment_all_components/weblogic_service.tf index 1b99d39a99d..5fc78f72aa5 100644 --- a/terraform/environments/delius-core/modules/environment_all_components/weblogic_service.tf +++ b/terraform/environments/delius-core/modules/environment_all_components/weblogic_service.tf @@ -192,6 +192,16 @@ resource "aws_security_group" "weblogic" { } } +resource "aws_vpc_security_group_ingress_rule" "name" { + security_group_id = aws_security_group.weblogic.id + description = "Allow traffic from ALB to weblogic task" + type = "ingress" + from_port = var.weblogic_config.frontend_container_port + to_port = var.weblogic_config.frontend_container_port + protocol = "TCP" + referenced_security_group_id = aws_security_group.delius_core_frontend_security_group.id +} + resource "aws_security_group_rule" "weblogic_allow_all_egress" { description = "Allow all outbound traffic to any IPv4 address" type = "egress" From 9d0577f36e63186decf5650f646f04645ac9af5e Mon Sep 17 00:00:00 2001 From: George Taylor Date: Fri, 6 Oct 2023 19:51:01 +0100 Subject: [PATCH 2/3] typo --- .../modules/environment_all_components/weblogic_service.tf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/terraform/environments/delius-core/modules/environment_all_components/weblogic_service.tf b/terraform/environments/delius-core/modules/environment_all_components/weblogic_service.tf index 5fc78f72aa5..2673d5022fd 100644 --- a/terraform/environments/delius-core/modules/environment_all_components/weblogic_service.tf +++ b/terraform/environments/delius-core/modules/environment_all_components/weblogic_service.tf @@ -198,7 +198,7 @@ resource "aws_vpc_security_group_ingress_rule" "name" { type = "ingress" from_port = var.weblogic_config.frontend_container_port to_port = var.weblogic_config.frontend_container_port - protocol = "TCP" + ip_protocol = "TCP" referenced_security_group_id = aws_security_group.delius_core_frontend_security_group.id } From 367ff2f42f06ff2706e4d5366796f5ca98ececc5 Mon Sep 17 00:00:00 2001 From: George Taylor Date: Fri, 6 Oct 2023 19:51:12 +0100 Subject: [PATCH 3/3] remove type --- .../modules/environment_all_components/weblogic_service.tf | 1 - 1 file changed, 1 deletion(-) diff --git a/terraform/environments/delius-core/modules/environment_all_components/weblogic_service.tf b/terraform/environments/delius-core/modules/environment_all_components/weblogic_service.tf index 2673d5022fd..c51e5dc6609 100644 --- a/terraform/environments/delius-core/modules/environment_all_components/weblogic_service.tf +++ b/terraform/environments/delius-core/modules/environment_all_components/weblogic_service.tf @@ -195,7 +195,6 @@ resource "aws_security_group" "weblogic" { resource "aws_vpc_security_group_ingress_rule" "name" { security_group_id = aws_security_group.weblogic.id description = "Allow traffic from ALB to weblogic task" - type = "ingress" from_port = var.weblogic_config.frontend_container_port to_port = var.weblogic_config.frontend_container_port ip_protocol = "TCP"