File tree Expand file tree Collapse file tree 7 files changed +19
-10
lines changed Expand file tree Collapse file tree 7 files changed +19
-10
lines changed Original file line number Diff line number Diff line change @@ -1130,7 +1130,7 @@ Default value: `'90s'`
11301130
11311131##### <a name =" -nginx--proxy_redirect " ></a >` proxy_redirect `
11321132
1133- Data type: ` Optional[String] `
1133+ Data type: ` Optional[Variant[Array[ String],String] ] `
11341134
11351135
11361136
@@ -2096,7 +2096,7 @@ Default value: `undef`
20962096
20972097##### <a name =" -nginx--resource--location--proxy_redirect " ></a >` proxy_redirect `
20982098
2099- Data type: ` Optional[String] `
2099+ Data type: ` Optional[Variant[Array[ String],String] ] `
21002100
21012101sets the text, which must be changed in response-header "Location" and
21022102"Refresh" in the response of the proxied server.
@@ -3622,7 +3622,7 @@ Default value: `$nginx::proxy_send_timeout`
36223622
36233623##### <a name =" -nginx--resource--server--proxy_redirect " ></a >` proxy_redirect `
36243624
3625- Data type: ` Optional[String] `
3625+ Data type: ` Optional[Variant[Array[ String],String] ] `
36263626
36273627Override the default proxy_redirect value of off.
36283628
Original file line number Diff line number Diff line change 322322 Integer $proxy_headers_hash_bucket_size = 64,
323323 Optional[String] $proxy_http_version = undef ,
324324 Nginx::Time $proxy_read_timeout = ' 90s' ,
325- Optional[String] $proxy_redirect = undef ,
325+ Optional[Variant[Array[ String],String]] $proxy_redirect = undef ,
326326 Nginx::Time $proxy_send_timeout = ' 90s' ,
327327 Array $proxy_set_header = [
328328 ' Host $host' ,
Original file line number Diff line number Diff line change 264264 ' index.php' ,
265265 ],
266266 Optional[String] $proxy = undef ,
267- Optional[String] $proxy_redirect = $nginx::proxy_redirect,
267+ Optional[Variant[Array[ String],String]] $proxy_redirect = $nginx::proxy_redirect,
268268 String $proxy_read_timeout = $nginx::proxy_read_timeout,
269269 String $proxy_connect_timeout = $nginx::proxy_connect_timeout,
270270 String $proxy_send_timeout = $nginx::proxy_send_timeout,
Original file line number Diff line number Diff line change 331331 Enum['on', 'off'] $spdy = $nginx::spdy,
332332 Enum['on', 'off'] $http2 = $nginx::http2,
333333 Optional[String] $proxy = undef ,
334- Optional[String] $proxy_redirect = undef ,
334+ Optional[Variant[Array[ String],String]] $proxy_redirect = undef ,
335335 String $proxy_read_timeout = $nginx::proxy_read_timeout,
336336 String $proxy_send_timeout = $nginx::proxy_send_timeout,
337337 $proxy_connect_timeout = $nginx::proxy_connect_timeout,
Original file line number Diff line number Diff line change 935935 value : 'value' ,
936936 match : %r{^\s +proxy_redirect\s +value;}
937937 } ,
938+ {
939+ title : 'should set proxy_redirect array' ,
940+ attr : 'proxy_redirect' ,
941+ value : %w[ value1 value2 ] ,
942+ match : [
943+ %r{^\s +proxy_redirect\s +value1;} ,
944+ %r{^\s +proxy_redirect\s +value2;} ,
945+ ] ,
946+ } ,
938947 {
939948 title : 'should not set proxy_redirect' ,
940949 attr : 'proxy_redirect' ,
Original file line number Diff line number Diff line change @@ -184,8 +184,8 @@ http {
184184<% if @client_body_buffer_size -%>
185185 client_body_buffer_size <%= @client_body_buffer_size %> ;
186186<% end -%>
187- <% if @proxy_redirect -%>
188- proxy_redirect <%= @proxy_redirect %> ;
187+ <% Array( @proxy_redirect).each do |value| -%>
188+ proxy_redirect <%= value %> ;
189189<% end -%>
190190<% if @_proxy_temp_path -%>
191191 proxy_temp_path <%= @_proxy_temp_path.join(' ') %> ;
Original file line number Diff line number Diff line change 33 proxy_read_timeout <%= @proxy_read_timeout %> ;
44 proxy_connect_timeout <%= @proxy_connect_timeout %> ;
55 proxy_send_timeout <%= @proxy_send_timeout %> ;
6- <% if @proxy_redirect -%>
7- proxy_redirect <%= @proxy_redirect %> ;
6+ <% Array( @proxy_redirect).each do |value| -%>
7+ proxy_redirect <%= value %> ;
88<% end -%>
99<% if @proxy_http_version -%>
1010 proxy_http_version <%= @proxy_http_version %> ;
You can’t perform that action at this time.
0 commit comments