aboutsummaryrefslogtreecommitdiffstats
path: root/config/bind/bind.inc
diff options
context:
space:
mode:
authorMarcello Coutinho <marcellocoutinho@gmail.com>2013-10-25 19:12:27 -0200
committerMarcello Coutinho <marcellocoutinho@gmail.com>2013-10-25 19:12:27 -0200
commit48a5d68e30e1f1568dae307feb30f5490615993e (patch)
tree2be37bd2bf9e4d5db7fabf1f1ff27ec3dc510566 /config/bind/bind.inc
parent23deffdfd766efdafc357b923262fb495af34730 (diff)
downloadpfsense-packages-48a5d68e30e1f1568dae307feb30f5490615993e.tar.gz
pfsense-packages-48a5d68e30e1f1568dae307feb30f5490615993e.tar.bz2
pfsense-packages-48a5d68e30e1f1568dae307feb30f5490615993e.zip
bind -remove unsed functions and fix sync code for automatic option.
Diffstat (limited to 'config/bind/bind.inc')
-rw-r--r--config/bind/bind.inc23
1 files changed, 5 insertions, 18 deletions
diff --git a/config/bind/bind.inc b/config/bind/bind.inc
index 66ed6301..21e88e15 100644
--- a/config/bind/bind.inc
+++ b/config/bind/bind.inc
@@ -693,19 +693,6 @@ EOD;
conf_mount_ro();
}
-function create_log_file(){
- conf_mount_rw();
- mwexec("touch ".CHROOT_LOCALBASE."/var/log/named.log");
- mwexec("chown bind:bind ".CHROOT_LOCALBASE."/var/log/named.log");
- mwexec("chmod 755 ".CHROOT_LOCALBASE."/var/log/named.log");
- conf_mount_ro();
-}
-
-function delete_log_file(){
- conf_mount_rw();
- mwexec("rm ".CHROOT_LOCALBASE."/var/log/named.log");
- conf_mount_ro();
-}
/* Uses XMLRPC to synchronize the changes to a remote node */
function bind_sync_on_changes() {
global $config, $g;
@@ -725,11 +712,11 @@ function bind_sync_on_changes() {
}
break;
case "auto":
- if (is_array($config['installedpackages']['carpsettings']) && is_array($config['installedpackages']['carpsettings']['config'])){
- $system_carp=$config['installedpackages']['carpsettings']['config'][0];
- $rs[0]['ipaddress']=$system_carp['synchronizetoip'];
- $rs[0]['username']=$system_carp['username'];
- $rs[0]['password']=$system_carp['password'];
+ if (is_array($config['hasync'])){
+ $hasync=$config['hasync'][0];
+ $rs[0]['ipaddress']=$hasync['synchronizetoip'];
+ $rs[0]['username']=$hasync['username'];
+ $rs[0]['password']=$hasync['password'];
}
else{
log_error("[bind] xmlrpc sync is enabled but there is no system backup hosts to push bind config.");