In order to support adding a second DNS server, the BIND zone configuration needs to be partially modularized. While the forwarder definitions for *pyrocufflink.blue*, etc. will remain the same, the *pyrocufflink.red* zone will be different, as it will be a slave zone on the second server. This commit breaks up the definition of the `named_zones` variable into two parts: * `pyrocufflink_red_zones`: This is a list of zone objects for *pyrocufflink.red* and its corresponding reverse zone. On *dns1.pyrocufflink.blue*, these are master zones. On the new server, these will be slaves. * `pyrocufflink_common_zones`: This is a list of zone objects for the zones that are the same on both servers, since they are all forwarding zones. Similarly, the `named_keys` variable only needs to be defined on the master, since DHCP will only send updates there.
25 lines
577 B
YAML
25 lines
577 B
YAML
pyrocufflink_red_zones:
|
|
- zone: pyrocufflink.red
|
|
type: master
|
|
default_records:
|
|
- name:
|
|
value: 172.30.0.4
|
|
- name:
|
|
type: AAAA
|
|
value: 2605:6000:3ccc:fb00::4:1
|
|
allow_update:
|
|
- '{ !{ !172.30.0.1; any; }; key dhcp-ddns; }'
|
|
- '{ !{ !localhost; any; }; key local-ddns; }'
|
|
ttl: 30
|
|
- zone: 1.31.172.in-addr.arpa
|
|
type: master
|
|
allow_update:
|
|
- '{ !{ !172.30.0.1; any; }; key dhcp-ddns; }'
|
|
- '{ !{ !localhost; any; }; key local-ddns; }'
|
|
ttl: 30
|
|
|
|
named_keys:
|
|
- name: dhcp-ddns
|
|
algorithm: hmac-md5
|
|
secret: +0zVSpY8oFrxl2F1qB8tT2HMgbuD31JurL9w4zilNCg=
|