ispman/bin/functions dnsload.functions.pl,1.4,1.5 dnsset.functions.pl,1.5,1.6
Joerg Delker <[email protected]>
| Newsgroups | gmane.comp.isp.ispman.cvs |
|---|---|
| Message-ID | <[email protected]> |
Update of /cvsroot/ispman/ispman/bin/functions
In directory sc8-pr-cvs11.sourceforge.net:/tmp/cvs-serv3558/bin/functions
Modified Files:
dnsload.functions.pl dnsset.functions.pl
Log Message:
adjusted to changed param of setDNSsOARecord
Index: dnsset.functions.pl
===================================================================
RCS file: /cvsroot/ispman/ispman/bin/functions/dnsset.functions.pl,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -d -r1.5 -r1.6
--- dnsset.functions.pl 29 May 2006 22:22:37 -0000 1.5
+++ dnsset.functions.pl 30 May 2006 20:38:56 -0000 1.6
@@ -34,13 +34,26 @@
}
sub set_soa {
- print "$opts{'d'}: Set SOA record @ARGV \n" if defined $opts{'v'};
- $ispman->setDNSsOARecord(
- $opts{'d'},
- join( " ",
- $ARGV[0], $ARGV[1], time(), $ARGV[2],
- $ARGV[3], $ARGV[4], $ARGV[5] )
- );
+ my $soa;
+ if ( $opts{'s'} ) {
+ my ( $var, $val ) = split("=",$opts{'s'});
+ print "$opts{'d'}: Set SOA record $var=$val\n" if defined $opts{'v'};
+ $soa = $ispman->getSOA( $opts{'d'} );
+ $soa->{$var} = $val;
+ }
+ else {
+ print "$opts{'d'}: Set SOA record @ARGV \n" if defined $opts{'v'};
+ $soa = {
+ 'primary' => $ARGV[0],
+ 'rootmail' => $ARGV[1],
+ 'serial' => time(),
+ 'refresh' => $ARGV[2],
+ 'retry' => $ARGV[3],
+ 'expire' => $ARGV[4],
+ 'minimum' => $ARGV[5]
+ };
+ }
+ $ispman->setDNSsOARecord( $opts{'d'}, $soa );
#dns set SOA primary rootmail refresh retry expire minimum
}
Index: dnsload.functions.pl
===================================================================
RCS file: /cvsroot/ispman/ispman/bin/functions/dnsload.functions.pl,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -d -r1.4 -r1.5
--- dnsload.functions.pl 30 May 2004 23:35:33 -0000 1.4
+++ dnsload.functions.pl 30 May 2006 20:38:56 -0000 1.5
@@ -22,8 +22,14 @@
sub set_soa {
my $domain = shift;
- $ispman->setDNSsOARecord( $domain,
- join( " ", $_[0], $_[1], time(), $_[2], $_[3], $_[4], $_[5] ) );
+ my $soa = { 'primary' => $_[0],
+ 'rootmail' => $_[1],
+ 'serial' => time(),
+ 'refresh' => $_[2],
+ 'retry' => $_[3],
+ 'expire' => $_[4],
+ 'minimum' => $_[5] };
+ $ispman->setDNSsOARecord( $domain, $soa );
}
1;
-------------------------------------------------------
All the advantages of Linux Managed Hosting--Without the Cost and Risk!
Fully trained technicians. The highest number of Red Hat certifications in
the hosting industry. Fanatical Support. Click to learn more
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=107521&bid=248729&dat=121642