@@ -450,7 +450,8 @@ resource "aws_lb_listener_rule" "this" {
450450 for_each = condition. value . host_header != null ? [condition . value . host_header ] : []
451451
452452 content {
453- values = host_header. value . values
453+ values = host_header. value . values
454+ regex_values = host_header. value . regex_values
454455 }
455456 }
456457
@@ -460,6 +461,7 @@ resource "aws_lb_listener_rule" "this" {
460461 content {
461462 http_header_name = http_header. value . http_header_name
462463 values = http_header. value . values
464+ regex_values = http_header. value . regex_values
463465 }
464466 }
465467
@@ -475,7 +477,8 @@ resource "aws_lb_listener_rule" "this" {
475477 for_each = condition. value . path_pattern != null ? [condition . value . path_pattern ] : []
476478
477479 content {
478- values = path_pattern. value . values
480+ values = path_pattern. value . values
481+ regex_values = path_pattern. value . regex_values
479482 }
480483 }
481484
@@ -501,6 +504,45 @@ resource "aws_lb_listener_rule" "this" {
501504 listener_arn = try (aws_lb_listener. this [each . value . listener_key ]. arn , each. value . listener_arn )
502505 priority = each. value . priority
503506
507+ dynamic "transform" {
508+ for_each = each. value . transform != null ? each. value . transform : {}
509+
510+ content {
511+ type = coalesce (transform. value . type , transform. key )
512+
513+ dynamic "host_header_rewrite_config" {
514+ for_each = transform. value . host_header_rewrite_config != null ? [transform . value . host_header_rewrite_config ] : []
515+
516+ content {
517+
518+ dynamic "rewrite" {
519+ for_each = host_header_rewrite_config. value . rewrite != null ? [host_header_rewrite_config . value . rewrite ] : []
520+
521+ content {
522+ regex = rewrite. value . regex
523+ replace = rewrite. value . replace
524+ }
525+ }
526+ }
527+ }
528+ dynamic "url_rewrite_config" {
529+ for_each = transform. value . url_rewrite_config != null ? [transform . value . url_rewrite_config ] : []
530+
531+ content {
532+
533+ dynamic "rewrite" {
534+ for_each = url_rewrite_config. value . rewrite != null ? [url_rewrite_config . value . rewrite ] : []
535+
536+ content {
537+ regex = rewrite. value . regex
538+ replace = rewrite. value . replace
539+ }
540+ }
541+ }
542+ }
543+ }
544+ }
545+
504546 tags = merge (
505547 local. tags ,
506548 each. value . tags ,
0 commit comments