Configuration of domains
David Morton
freeside at petra.osprey.net
Fri Apr 7 08:24:49 PDT 2000
I ran into another snag...
I get errors with this bit of code in svc_domain.pm line 37...
@nameservers=map {
/^\s*\d+\.\d+\.\d+\.\d+\s+([^\s]+)\s*$/
or die "Illegal line in $internic/nameservers";
$1;
} @ns;
@nameserver_ips=map {
/^\s*(\d+\.\d+\.\d+\.\d+)\s+([^\s]+)\s*$/
or die "Illegal line in $internic/nameservers!";
$1;
} @ns;
well, duh, because I haven't defined that configuration yet. :)
Why/when is this callback called? Can its call depend on whether or not
a configuration exists? :)
I thought I had a new format for configuration files all figured out,
until I discovered what this callback was doing, with subdirectories in
the filename.
I think I can hack around it, but it looks ugly.
where before you had a filename as such:
my($internic)="/registries/internic";
$tech_contact = $conf->config("$internic/tech_contact");
I put it into a section in my ini file:
[/registries/internic]
tech_contact=joedokes at osprey.net
I think what I'd like to do is add a third parameter to FS::Conf->config
to support the "section" of configuration. So then the call above would
become:
$tech_contact = $conf->config("tech_contact", $internic)
More information about the freeside-devel
mailing list