aboutsummaryrefslogtreecommitdiffstats
path: root/config/haproxy/haproxy.inc
diff options
context:
space:
mode:
authorsullrich <sullrich@pfsense.org>2009-12-15 19:50:38 -0500
committersullrich <sullrich@pfsense.org>2009-12-15 19:50:38 -0500
commit9e57bb0ac2fe675ec501bf26b411f637c590366e (patch)
treea4e10e10146a5d098fcacd5bceb5b856b55d61c7 /config/haproxy/haproxy.inc
parent18e200afa2bd68b91adfc1a2fef68cf16f98fb1c (diff)
downloadpfsense-packages-9e57bb0ac2fe675ec501bf26b411f637c590366e.tar.gz
pfsense-packages-9e57bb0ac2fe675ec501bf26b411f637c590366e.tar.bz2
pfsense-packages-9e57bb0ac2fe675ec501bf26b411f637c590366e.zip
Use ssl-hello-chk instead of httpchk when using https
Diffstat (limited to 'config/haproxy/haproxy.inc')
-rw-r--r--config/haproxy/haproxy.inc12
1 files changed, 6 insertions, 6 deletions
diff --git a/config/haproxy/haproxy.inc b/config/haproxy/haproxy.inc
index 65d09521..6e8c4261 100644
--- a/config/haproxy/haproxy.inc
+++ b/config/haproxy/haproxy.inc
@@ -149,19 +149,19 @@ function haproxy_configure() {
fwrite ($fd, "{$listenip}");
// https is an alias for tcp for clarity purpouses
- if(strtolower($backend['type']) == "https")
+ if(strtolower($backend['type']) == "https") {
$backend_type = "tcp";
- else
+ $httpchk = "ssl-hello-chk";
+ } else {
$backend_type = $backend['type'];
+ $httpchk = "httpchk";
+ }
fwrite ($fd, "\tmode\t\t\t" . $backend_type . "\n");
fwrite ($fd, "\tlog\t\t\tglobal\n");
fwrite ($fd, "\toption\t\t\tdontlognull\n");
fwrite ($fd, "\toption\t\t\thttpclose\n");
fwrite ($fd, "\toption\t\t\tforwardfor\n");
-
- if($backend['type'] == "https")
- fwrite ($fd, "\toption\t\t\tssl-hello-chk\n");
if($backend['max_connections'])
fwrite ($fd, "\tmaxconn\t\t\t" . $backend['max_connections'] . "\n");
@@ -184,7 +184,7 @@ function haproxy_configure() {
if($backend['cookie_name'])
fwrite ($fd, "\tcookie\t\t\t" . $backend['cookie_name'] . " insert indirect\n");
- fwrite ($fd, "\toption\t\t\thttpchk HEAD " . $backend['monitor_uri'] . " HTTP/1.0\n");
+ fwrite ($fd, "\toption\t\t\t{$httpchk} HEAD " . $backend['monitor_uri'] . " HTTP/1.0\n");
if($backend['stats_enabled']=='yes') {
fwrite ($fd, "\tstats\t\t\tenable\n");