bind: document named.conf

This commit is contained in:
Astro 2017-03-12 03:12:52 +01:00
parent 25b5f8b9fb
commit 8f64476c2a
1 changed files with 5 additions and 0 deletions

View File

@ -1,3 +1,5 @@
# Slaves rely on static IPv4 addrs over dn42. Do not contact them over
# their public addrs because our source addr is dynamic!
{% macro slaves() -%}
{%- if pillar['bind']['slaves'] -%}
allow-transfer {
@ -13,6 +15,7 @@
{%- endif -%}
{%- endmacro %}
# root domain
{%- set domain = pillar['bind']['root-domain'] %}
zone "{{ domain }}" IN {
type master;
@ -20,6 +23,7 @@ zone "{{ domain }}" IN {
{{ slaves() }}
};
# net zones
{%- for net, subnet4 in pillar['subnets-inet'].items() %}
{%- set domain = net ~ '.' ~ pillar['bind']['root-domain'] %}
zone "{{ domain }}" IN {
@ -29,6 +33,7 @@ zone "{{ domain }}" IN {
};
{%- endfor %}
# IPv4 reverse zones
{%- for domain in pillar['bind']['reverse-zones-inet'] %}
zone "{{ domain }}" IN {
type master;