27 lines
897 B
Plaintext
27 lines
897 B
Plaintext
@ IN SOA <%= data["zone"]["soa"] %> <%= data["zone"]["hostmaster"] %> (
|
|
<%= data["zone"]["serial"] %> ; serial
|
|
<%= data["zone"]["refresh"] %> ; refresh
|
|
<%= data["zone"]["retry"] %> ; retry
|
|
<%= data["zone"]["expire"] %> ; expire
|
|
<%= data["zone"]["minimum"] %>) ; minimum
|
|
<% data["network"].each do |name, value| -%>
|
|
<% if value["ns"] -%>
|
|
IN NS <%= name %>
|
|
<% end -%>
|
|
<% end -%>
|
|
|
|
<% data["network"].each do |name, value| -%>
|
|
<% if value["ns"] -%>
|
|
<% if value["ipv4"] -%>
|
|
<%= name %> A <%= NetAddr::CIDR.create(value["ipv4"]).ip(Short: true) %>
|
|
<% end -%>
|
|
<% if value["ipv6"] -%>
|
|
<%= name %> AAAA <%= NetAddr::CIDR.create(value["ipv6"]).ip(Short: true) %>
|
|
<% end -%>
|
|
<% end -%>
|
|
<% end -%>
|
|
|
|
<% pointers do |addr, name| -%>
|
|
<%= addr %> PTR <%= name %>.<%= data["zone"]["domain"] %>.
|
|
<% end -%>
|