add option to enable/disable generation of bind-configs for the system-hostname

Signed-off-by: Michael Kaufmann (d00p) <d00p@froxlor.org>
This commit is contained in:
Michael Kaufmann (d00p)
2014-06-02 12:35:45 +02:00
parent 0d04077d6e
commit f1eb5420a7
9 changed files with 48 additions and 14 deletions

View File

@@ -89,17 +89,19 @@ class bind {
}
// frolxor-hostname (#1090)
$hostname_arr = array(
'id' => 'none',
'domain' => Settings::Get('system.hostname'),
'customerid' => 'none',
'loginname' => 'froxlor.panel',
'bindserial' => date('Ymd').'00',
'dkim' => '0',
'iswildcarddomain' => '1',
'zonefile' => ''
);
$bindconf_file .= $this->_generateDomainConfig($hostname_arr, true);
if (Settings::get('system.dns_createhostnameentry') == 1) {
$hostname_arr = array(
'id' => 'none',
'domain' => Settings::Get('system.hostname'),
'customerid' => 'none',
'loginname' => 'froxlor.panel',
'bindserial' => date('Ymd').'00',
'dkim' => '0',
'iswildcarddomain' => '1',
'zonefile' => ''
);
$bindconf_file .= $this->_generateDomainConfig($hostname_arr, true);
}
$bindconf_file_handler = fopen(makeCorrectFile(Settings::Get('system.bindconf_directory') . '/froxlor_bind.conf'), 'w');
fwrite($bindconf_file_handler, $bindconf_file);