forked from .cyb/cyberman
Groundwork for NSD interface
This commit is contained in:
parent
cecd088b0a
commit
2d6f62eefe
|
@ -15,3 +15,8 @@ plugins:
|
|||
driver: 'SQLite'
|
||||
dbname: 'db.sqlite'
|
||||
log_queries: 1
|
||||
|
||||
nsd:
|
||||
enable: 1
|
||||
zone_conf: /var/nsd/etc/zones.conf
|
||||
zone_dir: /var/nsd/zones/master
|
||||
|
|
1
cpanfile
1
cpanfile
|
@ -9,6 +9,7 @@ requires "DBD::SQLite" => "0";
|
|||
requires "HTML::Entities" => "0";
|
||||
requires "Digest::Bcrypt" => "0";
|
||||
requires "Math::Random::Secure" => "0";
|
||||
requires "if" => "0";
|
||||
|
||||
requires "Plack::Middleware::Deflater" => "0";
|
||||
requires "Plack::Middleware::Session" => "0";
|
||||
|
|
|
@ -0,0 +1,10 @@
|
|||
package NSD::Interface;
|
||||
use strict;
|
||||
use warnings;
|
||||
use Dancer2 appname => "cyberman";
|
||||
|
||||
use Exporter;
|
||||
|
||||
our @EXPORT = qw();
|
||||
|
||||
1;
|
|
@ -4,6 +4,7 @@ use Dancer2 appname => "cyberman";
|
|||
use Dancer2::Plugin::Database;
|
||||
|
||||
use cyberman::Helper qw(auth_test);
|
||||
use if config->{"use_nsd"}, "NSD::Interface";
|
||||
|
||||
get '/domains' => sub {
|
||||
return auth_test() if auth_test();
|
||||
|
|
Loading…
Reference in New Issue