diff --git a/terraform/alb.tf b/terraform/alb.tf index b427344..1a773ea 100644 --- a/terraform/alb.tf +++ b/terraform/alb.tf @@ -30,7 +30,7 @@ module "alb" { health_check = { enabled = true path = "/" - protocol = "HTTP" # Customize this based on your needs + protocol = "HTTP" # Customize this based on your needs matcher = "200-299" # HTTP status codes that indicate a healthy response interval = 30 # Time in seconds between health checks timeout = 15 # Time in seconds to wait for a response before marking as failed diff --git a/terraform/modules/terraform-aws-s3-bucket/modules/notification/versions.tf b/terraform/modules/terraform-aws-s3-bucket/modules/notification/versions.tf index ff97a04..ddfcb0e 100644 --- a/terraform/modules/terraform-aws-s3-bucket/modules/notification/versions.tf +++ b/terraform/modules/terraform-aws-s3-bucket/modules/notification/versions.tf @@ -4,7 +4,7 @@ terraform { required_providers { aws = { source = "hashicorp/aws" - version = ">= 3.74" + version = ">= 5.0" } } } diff --git a/terraform/modules/terraform-aws-s3-bucket/modules/object/versions.tf b/terraform/modules/terraform-aws-s3-bucket/modules/object/versions.tf index a9c2eed..ddfcb0e 100644 --- a/terraform/modules/terraform-aws-s3-bucket/modules/object/versions.tf +++ b/terraform/modules/terraform-aws-s3-bucket/modules/object/versions.tf @@ -4,7 +4,7 @@ terraform { required_providers { aws = { source = "hashicorp/aws" - version = ">= 5.24" + version = ">= 5.0" } } } diff --git a/terraform/prod.tfvars b/terraform/prod.tfvars index 063b79c..8087c12 100644 --- a/terraform/prod.tfvars +++ b/terraform/prod.tfvars @@ -62,12 +62,12 @@ additional_settings = [ ] env_vars = { - "DB_HOST" = "ebs-ue1-eb-d-rds.cmuokqciitb8.us-east-1.rds.amazonaws.com" - "DB_PORT" = "3306" - "DB_USERNAME" = "elasticbeanstalk" - "DB_PASSWORD" = "AlXmBgEuzUl3h3qA" - "DB_NAME" = "elasticbeanstalk" - } + "DB_HOST" = "ebs-ue1-eb-d-rds.cmuokqciitb8.us-east-1.rds.amazonaws.com" + "DB_PORT" = "3306" + "DB_USERNAME" = "elasticbeanstalk" + "DB_PASSWORD" = "AlXmBgEuzUl3h3qA" + "DB_NAME" = "elasticbeanstalk" +} scheduled_actions = [ { diff --git a/terraform/s3.tf b/terraform/s3.tf index 8d26fec..d0e6ce5 100644 --- a/terraform/s3.tf +++ b/terraform/s3.tf @@ -18,4 +18,4 @@ module "s3_bucket" { tags = module.naming.resources.s3.tags -} +} diff --git a/terraform/secrets_manager.tf b/terraform/secrets_manager.tf index ec621c2..c3ed5b0 100644 --- a/terraform/secrets_manager.tf +++ b/terraform/secrets_manager.tf @@ -10,6 +10,6 @@ module "secrets_manager" { password = module.rds.db_instance_password }) -# tags = module.naming.resources.secrets_manager.tags + # tags = module.naming.resources.secrets_manager.tags } diff --git a/terraform/sg.tf b/terraform/sg.tf index b572b0b..005b721 100644 --- a/terraform/sg.tf +++ b/terraform/sg.tf @@ -24,6 +24,13 @@ resource "aws_security_group" "alb" { cidr_blocks = ["0.0.0.0/0"] } + # egress { + # from_port = 8080 + # to_port = 8080 + # protocol = "tcp" + # security_groups = [aws_security_group.eb_instances.id] # Allow traffic to EB instances on port 8080 + # } + # Outbound rule to allow all traffic egress { from_port = 0 @@ -92,6 +99,13 @@ resource "aws_security_group" "eb_instances" { security_groups = [aws_security_group.alb.id] } + ingress { + from_port = 8080 + to_port = 8080 + protocol = "tcp" + security_groups = [aws_security_group.alb.id] # Allow traffic from ALB only + } + egress { from_port = 0 to_port = 0