Obsolete
/
dnsmanagerv1
Archived
3
0
Fork 0

bind transfert de zone + nsslavev4 v6 + nsd restart

master
Philippe Pittoli 2014-05-08 17:44:55 +02:00
parent 21ef161e87
commit a615bd6205
4 changed files with 7 additions and 3 deletions

View File

@ -18,7 +18,7 @@ has dbh => ( is => 'rw', builder => '_void');
has dnsi => ( is => 'rw', builder => '_void'); has dnsi => ( is => 'rw', builder => '_void');
has dnsisec => ( is => 'rw', builder => '_void'); has dnsisec => ( is => 'rw', builder => '_void');
has um => ( is => 'rw', builder => '_void'); has um => ( is => 'rw', builder => '_void');
has [ qw/zdir dbname dbhost dbport dbuser dbpass sgbd dnsapp dnsappsec sshhost sshhostsec sshuser sshusersec sshport sshportsec nsmasterv4 nsmasterv6 dnsslavekey/ ] => qw/is ro required 1/; has [ qw/zdir dbname dbhost dbport dbuser dbpass sgbd dnsapp dnsappsec sshhost sshhostsec sshuser sshusersec sshport sshportsec nsmasterv4 nsmasterv6 nsslavev4 nsslavev6 dnsslavekey/ ] => qw/is ro required 1/;
sub _void { my $x = ''; \$x; } sub _void { my $x = ''; \$x; }
### users ### users

View File

@ -12,7 +12,7 @@ sub reload_sec {
system('ssh -p ' . $self->data->sshportsec . ' ' system('ssh -p ' . $self->data->sshportsec . ' '
. $self->data->sshusersec . '@' . $self->data->sshhostsec . $self->data->sshusersec . '@' . $self->data->sshhostsec
. ' "sudo nsdc rebuild 2>/dev/null 1>/dev/null && sudo nsdc reload 2>/dev/null 1>/dev/null "'); . ' "sudo nsdc rebuild 2>/dev/null 1>/dev/null && sudo nsdc restart 2>/dev/null 1>/dev/null "');
} }
sub _reload_conf { sub _reload_conf {

View File

@ -19,7 +19,7 @@ sub addzone {
$command .= "'$opt'"; $command .= "'$opt'";
} }
else { else {
$command .= "'{ type master; file \"$zdir/$zname\"; };'" $command .= "'{ type master; file \"$zdir/$zname\"; allow-transfer { ". $self->data->nsslavev4 . '; '. $self->data->nsslavev6 . "; }; notify yes; };'";
} }
$command .= " 2>/dev/null 1>/dev/null"; $command .= " 2>/dev/null 1>/dev/null";

View File

@ -32,6 +32,10 @@ sshport = 2222
nsmasterv4 = 89.234.141.65 nsmasterv4 = 89.234.141.65
nsmasterv6 = 2a00:5881:8100:1000::2 nsmasterv6 = 2a00:5881:8100:1000::2
# name the IP of the slave named server
nsslavev4 = 91.224.149.146
nsslavev6 = 2a01:6600:8081:9200::1
# to access to the slave DNS server # to access to the slave DNS server
sshhostsec = host sshhostsec = host
sshusersec = dnsmanager sshusersec = dnsmanager