Skip to content

Commit 527899e

Browse files
fix some bugs with ROUTER_SLOW_LORIS_TIMEOUT
validate inputs from ROUTER_SLOWLORIS_TIMEOUT Take a suggestions from the comments in BZ1328037 on timeout http-keep-alive
1 parent 9ac6923 commit 527899e

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

images/router/haproxy/conf/haproxy-config.template

+6-1
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,12 @@ defaults
3939
option httplog
4040
log global
4141
{{ end }}
42-
timeout http-request {{env "ROUTER_SLOWLORIS_TIMEOUT" "10s" }}
42+
{{ if (matchPattern "[1-9][0-9]*(us|ms|s|m|h|d)?" (env "ROUTER_SLOWLORIS_TIMEOUT" "")) }}
43+
timeout http-request {{env "ROUTER_SLOWLORIS_TIMEOUT" "" }}
44+
{{ else }}
45+
timeout http-request 10s
46+
{{ end }}
47+
timeout http-keep-alive 30s
4348
timeout connect 5s
4449
timeout client 30s
4550
timeout server 30s

0 commit comments

Comments
 (0)