aboutsummaryrefslogtreecommitdiffstats
path: root/config
diff options
context:
space:
mode:
Diffstat (limited to 'config')
-rw-r--r--config/haproxy/haproxy.inc6
-rwxr-xr-xconfig/haproxy/haproxy_servers_edit.php10
2 files changed, 15 insertions, 1 deletions
diff --git a/config/haproxy/haproxy.inc b/config/haproxy/haproxy.inc
index 6bb3242b..f8b5efbf 100644
--- a/config/haproxy/haproxy.inc
+++ b/config/haproxy/haproxy.inc
@@ -227,8 +227,12 @@ function haproxy_configure() {
} else {
$server_ports[] = $server['port'];
}
+ if($server['advanced'])
+ $advanced_txt = " " . $server['advanced'];
+ else
+ $advanced_txt = "";
foreach($server_ports as $pport)
- fwrite ($fd, "\tserver\t\t\t" . $server['name'] . " " . $server['address'].":" . $pport . " $cookie " . " check inter 1000 weight " . $server['weight'] . "\n");
+ fwrite ($fd, "\tserver\t\t\t" . $server['name'] . " " . $server['address'].":" . $pport . " $cookie " . " check inter 1000 weight " . $server['weight'] . "{$advanced_txt}\n");
}
}
}
diff --git a/config/haproxy/haproxy_servers_edit.php b/config/haproxy/haproxy_servers_edit.php
index 8125bf6b..db44dc72 100755
--- a/config/haproxy/haproxy_servers_edit.php
+++ b/config/haproxy/haproxy_servers_edit.php
@@ -53,6 +53,7 @@ if (isset($id) && $a_server[$id]) {
$pconfig['weight'] = $a_server[$id]['weight'];
$pconfig['cookie'] = $a_server[$id]['cookie'];
$pconfig['status'] = $a_server[$id]['status'];
+ $pconfig['advanced'] = $a_server[$id]['advanced'];
}
$changedesc = "Services: HAProxy: Servers: ";
@@ -122,6 +123,7 @@ if ($_POST) {
update_if_changed("weight", $server['weight'], $_POST['weight']);
update_if_changed("status", $server['status'], $_POST['status']);
update_if_changed("address", $server['address'], $_POST['address']);
+ update_if_changed("advanced", $server['advanced'], $_POST['advanced']);
if (isset($id) && $a_server[$id]) {
$a_server[$id] = $server;
@@ -297,6 +299,14 @@ function clearcombo(){
</td>
</tr>
<tr align="left">
+ <td width="22%" valign="top" class="vncellreq">Advanced pass thru</td>
+ <td width="78%" class="vtable" colspan="2">
+ <textarea name='advanced' rows="4" cols="70" id='advanced'><?php echo $pconfig['advanced']; ?></textarea>
+ <br/>
+ NOTE: paste text into this box that you would like to pass thru.
+ </td>
+ </tr>
+ <tr align="left">
<td width="22%" valign="top">&nbsp;</td>
<td width="78%">
<input name="Submit" type="submit" class="formbtn" value="Save">