aboutsummaryrefslogtreecommitdiffstats
path: root/packages/carp_sync_server.php
diff options
context:
space:
mode:
authorScott Ullrich <sullrich@pfsense.org>2005-03-14 19:55:02 +0000
committerScott Ullrich <sullrich@pfsense.org>2005-03-14 19:55:02 +0000
commite0bcb1df5f596f9a66f24b296418506597116e62 (patch)
tree3fbd232f23d480a75c2665cc0b0426d2ea72b21d /packages/carp_sync_server.php
parent508fe215e533f231512149ac3572e0691b5c9e72 (diff)
downloadpfsense-packages-e0bcb1df5f596f9a66f24b296418506597116e62.tar.gz
pfsense-packages-e0bcb1df5f596f9a66f24b296418506597116e62.tar.bz2
pfsense-packages-e0bcb1df5f596f9a66f24b296418506597116e62.zip
* Allow aliases, nat, traffic shaping and firewall rules syncing status to be turned on or off
Diffstat (limited to 'packages/carp_sync_server.php')
-rw-r--r--packages/carp_sync_server.php23
1 files changed, 17 insertions, 6 deletions
diff --git a/packages/carp_sync_server.php b/packages/carp_sync_server.php
index cb292488..417a59f6 100644
--- a/packages/carp_sync_server.php
+++ b/packages/carp_sync_server.php
@@ -40,13 +40,24 @@ if($config['installedpackages']['carpsettings']['config'] != "")
$rules = return_filename_as_string("{$g['tmp_path']}/rules_section.txt");
$aliases = return_filename_as_string("{$g['tmp_path']}/aliases_section.txt");
$nat = return_filename_as_string("{$g['tmp_path']}/nat_section.txt");
- restore_config_section("filter", $rules);
- restore_config_section("aliases", $aliases);
- restore_config_section("nat", $nat);
+ $trafficshaper = return_filename_as_string("{$g['tmp_path']}/trafficshaper_section.txt");
+ if($rules <> "") {
+ restore_config_section("filter", $rules);
+ unlink("{$g['tmp_path']}/rules_section.txt");
+ }
+ if($aliases <> "") {
+ restore_config_section("aliases", $aliases);
+ unlink("{$g['tmp_path']}/aliases_section.txt");
+ }
+ if($nat <> "") {
+ restore_config_section("nat", $nat);
+ unlink("{$g['tmp_path']}/nat_section.txt");
+ }
+ if($trafficshaper <> "") {
+ restore_config_section("shaper", $trafficshaper);
+ unlink("{$g['tmp_path']}/nat_section.txt");
+ }
filter_configure();
- unlink("{$g['tmp_path']}/rules_section.txt");
- unlink("{$g['tmp_path']}/aliases_section.txt");
- unlink("{$g['tmp_path']}/nat_section.txt");
}
?> \ No newline at end of file