Ajout du TLD contenu dans le fichier de configuration.

Suppression des possibles "point" doublons.
	- si l'utilisateur entre "mondomaine." par exempe.
master
Julien Simonet 2014-01-20 19:45:48 +01:00
parent c4f54bfd0d
commit 8ebd61261f
2 changed files with 13 additions and 2 deletions

View File

@ -1,11 +1,18 @@
# TLD
# Must contains the first "."
tld = ".netlib.re"
# Database Options
sgbd = mysql
dbname = dnsmanager
host = localhost
# other options : see DBI module
sgbd = mysql
# default port for mysql
port = 3306
user = bla
passwd = HardPass4bla
# other options : see DBI module
# possible options for dnsserver : bind rndc
dnsapp = rndc
zones_path = "/srv/named/"

View File

@ -137,6 +137,10 @@ prefix '/domain' => sub {
else
{
# Add tld
my $domain = param('domain').$cfg->param('tld');
$domain =~ s/\.{2,}/\./g;
# create domain
my $app = initco();
$app->add_domain( session('login'), param('domain') );
redirect '/home';