diff --git a/group_vars/dns.yml b/group_vars/dns.yml index da9ca30..67cf8b0 100644 --- a/group_vars/dns.yml +++ b/group_vars/dns.yml @@ -15,3 +15,7 @@ zone_list: records: [] - name: wg.chapo.li records: [] + +forward_zones: + - name: internal.faercol.me + server: 192.168.1.12 \ No newline at end of file diff --git a/roles/dns/templates/named.conf.local.j2 b/roles/dns/templates/named.conf.local.j2 index 9e039fc..af17d7b 100644 --- a/roles/dns/templates/named.conf.local.j2 +++ b/roles/dns/templates/named.conf.local.j2 @@ -20,6 +20,14 @@ view "internal" { {% endif %} }; {% endfor %} + +{% for zone in forward_zones %} + zone "{{ zone.name }}" { + type forward; + forward only; + forwarders { {{ zone.server }}; }; + }; +{% endfor %} }; view "public" {