From 4faa97a29e62d37ff7a75488c82e39cd909feb96 Mon Sep 17 00:00:00 2001 From: jim-p Date: Thu, 29 Aug 2013 12:34:20 -0400 Subject: Add a manual config validation option to HAproxy (using -c to only check config file) --- config/haproxy/haproxy_global.php | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'config/haproxy/haproxy_global.php') diff --git a/config/haproxy/haproxy_global.php b/config/haproxy/haproxy_global.php index c09b202f..aa046544 100755 --- a/config/haproxy/haproxy_global.php +++ b/config/haproxy/haproxy_global.php @@ -89,6 +89,12 @@ if ($_POST) { touch($d_haproxyconfdirty_path); write_config(); } + + if ($_POST['Submit'] == "Save and Check Config") { + $check_output = haproxy_check_config(); + if (empty($check_output)) + $check_output = "No output."; + } } } @@ -159,6 +165,14 @@ function enable_change(enable_change) {
+ + + @@ -386,6 +400,7 @@ function enable_change(enable_change) { -- cgit v1.2.3
+Configuration check output: +
+
+
+
General settings
  +