You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: variables.tf
+21-5Lines changed: 21 additions & 5 deletions
Original file line number
Diff line number
Diff line change
@@ -118,10 +118,9 @@ variable "https_ports" {
118
118
/*
119
119
Other options for listeners (The same are valid also for https_ports variable):
120
120
121
-
Redirect (Force HTTPS):
122
121
variable "http_ports" {
123
-
description = "Map containing objects with two fields, listener_port and the target_group_port to redirect HTTP requests"
124
-
type = map
122
+
description = "Map containing objects to define listeners behaviour based on type field. If type field is `forward`, include listener_port and the target_group_port. For `redirect` type, include listener port, host, path, port, protocol, query and status_code. For `fixed-response`, include listener_port, content_type, message_body and status_code"
123
+
type = map(any)
125
124
default = {
126
125
force_https = {
127
126
type = "redirect"
@@ -135,10 +134,11 @@ Redirect (Force HTTPS):
135
134
}
136
135
}
137
136
}
137
+
138
138
Fixed response:
139
139
variable "http_ports" {
140
-
description = "Map containing objects with two fields, listener_port and the target_group_port to redirect HTTP requests"
141
-
type = map
140
+
description = "Map containing objects to define listeners behaviour based on type field. If type field is `forward`, include listener_port and the target_group_port. For `redirect` type, include listener port, host, path, port, protocol, query and status_code. For `fixed-response`, include listener_port, content_type, message_body and status_code"
141
+
type = map(any)
142
142
default = {
143
143
fixed_response = {
144
144
type = "fixed-response"
@@ -149,6 +149,22 @@ Fixed response:
149
149
}
150
150
}
151
151
}
152
+
153
+
Additionally, you can have an HTTPS listener forwarding traffic to an HTTP target group by setting `target_group_protocol` to `HTTP`. The default for `https_ports` variable is `HTTPS`:
154
+
155
+
variable "https_ports" {
156
+
description = "Map containing objects to define listeners behaviour based on type field. If type field is `forward`, include listener_port and the target_group_port. For `redirect` type, include listener port, host, path, port, protocol, query and status_code. For `fixed-response`, include listener_port, content_type, message_body and status_code"
0 commit comments