]> git.openstreetmap.org Git - dns.git/commitdiff
Drop unused A records for clustered CDN nodes
authorTom Hughes <tom@compton.nu>
Tue, 7 Apr 2020 21:48:03 +0000 (22:48 +0100)
committerTom Hughes <tom@compton.nu>
Tue, 7 Apr 2020 21:48:03 +0000 (22:48 +0100)
bin/mkgeo

index 9cfb6c124c6b9e421935af4126136df7c17426d5..ce0ff2f10c6a19db32408eaf168aad252f0616ca 100755 (executable)
--- a/bin/mkgeo
+++ b/bin/mkgeo
@@ -273,12 +273,14 @@ foreach my $cluster (sort { $a->{name} cmp $b->{name} } values %$clusters)
 {
     my $name = $cluster->{name};
 
-    output_server($zonefile, "${name}.${zone}", $cluster);
-
     if (@{$cluster->{servers}} > 1)
     {
         output_server($zonefile, "${name}-%02d.${zone}", $cluster);
     }
+    else
+    {
+        output_server($zonefile, "${name}.${zone}", $cluster);
+    }
 }
 
 # Output the GeoJSON text