Modify GenerateZoneFilesAction to create output files more in line with standard DNS format

In standard DNS format, the first thing on an A, NS or DS definition line is a domain label relative to the zone, which in our case is a TLD. However, the generate_zone_files command prints out fully qualified host and domain names, resulting in a discrepancy when compared to the contents of the DNS subsystem. This CL removes the TLD suffix, which should remove one preprocessing step before file comparison.

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=166103705
This commit is contained in:
mountford 2017-08-22 13:15:35 -07:00 committed by Ben McIlwain
parent e94ab94d13
commit 91d4fdb9a8
2 changed files with 34 additions and 17 deletions

View file

@ -1,14 +1,14 @@
$ORIGIN tld.
bar.tld 222 IN NS ns.bar.tld.
bar.tld 222 IN NS ns.foo.tld.
bar 222 IN NS ns.bar.tld.
bar 222 IN NS ns.foo.tld.
ns.bar.tld 11 IN A 127.0.0.1
ns.bar.tld 11 IN AAAA 0:0:0:0:0:0:0:1
ns.bar 11 IN A 127.0.0.1
ns.bar 11 IN AAAA 0:0:0:0:0:0:0:1
ns-only.tld 222 IN NS ns.foo.tld.
ns-only.tld 222 IN NS ns.bar.tld.
ns-only 222 IN NS ns.foo.tld.
ns-only 222 IN NS ns.bar.tld.
ns-and-ds.tld 222 IN NS ns.foo.tld.
ns-and-ds.tld 222 IN NS ns.bar.tld.
ns-and-ds.tld 3333 IN DS 1 2 3 000102
ns-and-ds 222 IN NS ns.foo.tld.
ns-and-ds 222 IN NS ns.bar.tld.
ns-and-ds 3333 IN DS 1 2 3 000102