aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJoachim Tingvold <joachim@tingvold.com>2014-04-18 23:18:31 +0200
committerJoachim Tingvold <joachim@tingvold.com>2014-04-18 23:18:31 +0200
commitdcd697a74a47fa00525af9b21e8a21711aa5c828 (patch)
tree5baa895fd303514bcedb0c9b579de5db931896fb
parent9921526800e5f2aced28381f07275b1c0693dd4f (diff)
Change DNS for switch-entry for each zone.
-rwxr-xr-xtools/dlink-ng2dns.pl12
1 files changed, 6 insertions, 6 deletions
diff --git a/tools/dlink-ng2dns.pl b/tools/dlink-ng2dns.pl
index a7e01a8..06f9d05 100755
--- a/tools/dlink-ng2dns.pl
+++ b/tools/dlink-ng2dns.pl
@@ -38,9 +38,9 @@ while (<STDIN>)
my $text_info = $distro . " - " . join(' + ', @ports) . ", po" . $ponum . ", gwaddr " . $gwaddr;
# A-record to the switch
- print "prereq nxdomain " . $sw_fqdn . "\n" unless $delete;
- print "update add " . $sw_fqdn . " \t 3600 IN A \t " . $ipaddr . "\n" unless $delete;
- print "update delete " . $sw_fqdn . " \t IN A\n" if $delete;
+ print "prereq nxdomain sw." . $fqdn . "\n" unless $delete;
+ print "update add sw." . $fqdn . " \t 3600 IN A \t " . $ipaddr . "\n" unless $delete;
+ print "update delete sw." . $fqdn . " \t IN A\n" if $delete;
print "send\n";
# PTR to the switch
@@ -50,9 +50,9 @@ while (<STDIN>)
print "send\n";
# TXT-record with details
- print "update delete " . $sw_fqdn . " IN TXT\n" unless $delete;
- print "update add " . $sw_fqdn . " \t 3600 IN TXT \t \"" . $text_info . "\"\n" unless $delete;
- print "update delete " . $sw_fqdn . " \t IN TXT\n" if $delete;
+ print "update delete sw." . $fqdn . " IN TXT\n" unless $delete;
+ print "update add sw." . $fqdn . " \t 3600 IN TXT \t \"" . $text_info . "\"\n" unless $delete;
+ print "update delete sw." . $fqdn . " \t IN TXT\n" if $delete;
print "send\n";
# A and AAAA-record to the gateway/router