added check if we are master for a zone
Signed-off-by: tracer <tracer@24unix.net>
This commit is contained in:
parent
6b1329eb3c
commit
c9b1d097c1
|
@ -21,7 +21,6 @@ class DomainController
|
|||
private string $localZonesDir;
|
||||
private string $namedConfLocalFile;
|
||||
private string $zoneCachePath;
|
||||
private string $keyhelpNamedCond;
|
||||
|
||||
|
||||
public function __construct(private NameserverRepository $nameserverRepository, private ApiController $checkController, private DomainRepository $domainRepository, private PanelRepository $panelRepository, private array $config, private Logger $log)
|
||||
|
@ -35,7 +34,6 @@ class DomainController
|
|||
$this->localZonesDir = '/etc/bind/zones/';
|
||||
$this->namedConfLocalFile = '/etc/bind/named.conf.local';
|
||||
$this->zoneCachePath = '/var/cache/bind/';
|
||||
$this->keyhelpNamedCond = '/etc/bind/named.conf.keyhelp';
|
||||
}
|
||||
|
||||
|
||||
|
@ -210,7 +208,7 @@ class DomainController
|
|||
}
|
||||
|
||||
// check if we're a master zone
|
||||
if ($this->isMasterZone($domain->getName())) {
|
||||
if ($this->isMasterZone(domain: $domain)) {
|
||||
echo 'We are zone master for ' . $domain->getName() . PHP_EOL;
|
||||
exit(1);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue