diff options
author | Marcello Coutinho <marcellocoutinho@gmail.com> | 2013-12-09 18:15:18 -0200 |
---|---|---|
committer | Marcello Coutinho <marcellocoutinho@gmail.com> | 2013-12-09 18:15:18 -0200 |
commit | 37adca57db41b835b80d8e9eea5545dd6cb694b1 (patch) | |
tree | 252ff04e5885f5e99852fe59b278e76e9e113a71 | |
parent | 694e9f735bb16c7fed83bb26ecaff2ec05a4e1ce (diff) | |
download | pfsense-packages-37adca57db41b835b80d8e9eea5545dd6cb694b1.tar.gz pfsense-packages-37adca57db41b835b80d8e9eea5545dd6cb694b1.tar.bz2 pfsense-packages-37adca57db41b835b80d8e9eea5545dd6cb694b1.zip |
varnish3 - fix save lb_director save error on pfsense 2.1
-rw-r--r-- | config/varnish3/varnish.inc | 7 | ||||
-rw-r--r-- | config/varnish3/varnish_backends.xml | 4 | ||||
-rw-r--r-- | config/varnish3/varnish_lb_directors.xml | 3 | ||||
-rw-r--r-- | config/varnish3/varnish_settings.xml | 5 | ||||
-rw-r--r-- | config/varnish3/varnish_sync.xml | 1 | ||||
-rw-r--r-- | pkg_config.8.xml | 2 | ||||
-rw-r--r-- | pkg_config.8.xml.amd64 | 2 |
7 files changed, 8 insertions, 16 deletions
diff --git a/config/varnish3/varnish.inc b/config/varnish3/varnish.inc index 983804c9..1895d214 100644 --- a/config/varnish3/varnish.inc +++ b/config/varnish3/varnish.inc @@ -65,8 +65,13 @@ function varnish_settings_post_validate($post, $input_errors) { } function varnish_lb_directors_post_validate($post, $input_errors) { - if (preg_match("/[^a-zA-Z0-9]/", $post['directorname'])) + if (preg_match("/[^a-zA-Z0-9]/", $post['directorname'])){ $input_errors[] = "The directorname name must only contain the characters a-Z or 0-9"; + } + else{ + if(empty($post['failover'])) + $_POST['failover'] = $post['directorname']; + } if(stristr($post['directorurl'], 'http')) $input_errors[] = "You do not need to include the http:// string in the director URL"; if($post['grace'] && ! preg_match("/^\d+(h|m|s)$/",$post['grace'])) diff --git a/config/varnish3/varnish_backends.xml b/config/varnish3/varnish_backends.xml index 28e7caca..58216279 100644 --- a/config/varnish3/varnish_backends.xml +++ b/config/varnish3/varnish_backends.xml @@ -155,7 +155,6 @@ <fields> <field> <fielddescr>BackendSettings</fielddescr> - <fieldname>BackendSettings</fieldname> <type>listtopic</type> <name>Backend settings</name> </field> @@ -189,7 +188,6 @@ </field> <field> <fielddescr>PerformanceMetrics</fielddescr> - <fieldname>PerformanceMetrics</fieldname> <type>listtopic</type> <name>Performance metrics</name> </field> @@ -207,7 +205,6 @@ </field> <field> <fielddescr>ProbeInfo</fielddescr> - <fieldname>ProbeInfo</fieldname> <type>listtopic</type> <name>Probe settings</name> </field> @@ -250,7 +247,6 @@ </field> <field> <fielddescr>Mappings</fielddescr> - <fieldname>Mappings</fieldname> <type>listtopic</type> <name>Backend Mappings</name> </field> diff --git a/config/varnish3/varnish_lb_directors.xml b/config/varnish3/varnish_lb_directors.xml index b9d8cc24..99a945d5 100644 --- a/config/varnish3/varnish_lb_directors.xml +++ b/config/varnish3/varnish_lb_directors.xml @@ -137,7 +137,6 @@ <fields> <field> <fielddescr>DirectorSettings</fielddescr> - <fieldname>Director Settings</fieldname> <type>listtopic</type> <name>Director settings</name> </field> @@ -209,7 +208,6 @@ </field> <field> <fielddescr>Backendlist</fielddescr> - <fieldname>Backendlist</fieldname> <type>listtopic</type> <name>Backend Settings</name> </field> @@ -249,7 +247,6 @@ </field> <field> <fielddescr>FailoverSettings</fielddescr> - <fieldname>FailoverSettings</fieldname> <type>listtopic</type> <name>Failover Settings</name> </field> diff --git a/config/varnish3/varnish_settings.xml b/config/varnish3/varnish_settings.xml index 38c68a03..bbb8d321 100644 --- a/config/varnish3/varnish_settings.xml +++ b/config/varnish3/varnish_settings.xml @@ -80,7 +80,6 @@ <fields> <field> <fielddescr>Listening</fielddescr> - <fieldname>Listening</fieldname> <type>listtopic</type> <name>Daemon options</name> </field> @@ -112,7 +111,6 @@ </field> <field> <fielddescr>StorageTypeLT</fielddescr> - <fieldname>StorageTypeLT</fieldname> <type>listtopic</type> <name>Storage type</name> </field> @@ -135,7 +133,6 @@ <field> <fielddescr>WorkerThreadLT</fielddescr> - <fieldname>WorkerThreadLT</fieldname> <type>listtopic</type> <name>Worker thread configuration</name> </field> @@ -159,7 +156,6 @@ </field> <field> <fielddescr>BasicVCLLT</fielddescr> - <fieldname>BasicVCLLT</fieldname> <type>listtopic</type> <name>General VCL Settings</name> </field> @@ -245,7 +241,6 @@ </field> <field> <fielddescr>ErrorVCLLT</fielddescr> - <fieldname>ErrorVCLLT</fieldname> <type>listtopic</type> <name>Error Settings</name> </field> diff --git a/config/varnish3/varnish_sync.xml b/config/varnish3/varnish_sync.xml index fd387fdb..d81851b1 100644 --- a/config/varnish3/varnish_sync.xml +++ b/config/varnish3/varnish_sync.xml @@ -80,7 +80,6 @@ <fields> <field> <type>listtopic</type> - <fieldname>temp</fieldname> <name>Enable Varnish configuration sync</name> </field> <field> diff --git a/pkg_config.8.xml b/pkg_config.8.xml index f5e097aa..97f0f868 100644 --- a/pkg_config.8.xml +++ b/pkg_config.8.xml @@ -800,7 +800,7 @@ <website>http://varnish-cache.org</website> <pkginfolink>http://doc.pfsense.org/index.php/Varnish_package</pkginfolink> <category>Services</category> - <version>3.0.4 pkg v.0.2</version> + <version>3.0.4 pkg v.0.2.1</version> <status>RC</status> <required_version>2.0</required_version> <config_file>http://www.pfsense.com/packages/config/varnish3/varnish_backends.xml</config_file> diff --git a/pkg_config.8.xml.amd64 b/pkg_config.8.xml.amd64 index 2e4ee125..aea4f772 100644 --- a/pkg_config.8.xml.amd64 +++ b/pkg_config.8.xml.amd64 @@ -787,7 +787,7 @@ <website>http://varnish-cache.org</website> <pkginfolink>http://doc.pfsense.org/index.php/Varnish_package</pkginfolink> <category>Services</category> - <version>3.0.4 pkg v.0.2</version> + <version>3.0.4 pkg v.0.2.1</version> <status>RC</status> <required_version>2.0</required_version> <config_file>http://www.pfsense.com/packages/config/varnish3/varnish_backends.xml</config_file> |