Skip creating reverse zonefiles for now as RFC1918 ones will conflict with each other
Change-Id: Id6f58ef6b68633befa438e9b9f28b3d325cae36d
diff --git a/molecule/default/converge.yml b/molecule/default/converge.yml
index e389b8f..e88b105 100644
--- a/molecule/default/converge.yml
+++ b/molecule/default/converge.yml
@@ -10,18 +10,28 @@
dns_zones:
example.com:
serial: 20201102
- ip_range: 192.168.1.1/24
+ ip_range: 10.0.0.1/24
ns:
- gw.example.com.
a:
- gw: 192.168.1.1
- host1: 192.168.1.2
- host2: 192.168.1.3
- printer: 192.168.1.4
+ gw: 10.0.0.1
+ host1: 10.0.0.2
+ host2: 10.0.0.3
+ printer: 10.0.0.4
cname:
lpr: printer.example.com.
srv: {}
txt: {}
+ example.org:
+ serial: 20201102
+ ip_range: 10.0.10.1/24
+ ns:
+ - gw2.example.com.
+ a:
+ gw2: 10.0.10.1
+ cname: {}
+ srv: {}
+ txt: {}
tasks:
- name: "Include nsd"
include_role:
diff --git a/molecule/default/verify.yml b/molecule/default/verify.yml
index a4851a1..43cba44 100644
--- a/molecule/default/verify.yml
+++ b/molecule/default/verify.yml
@@ -17,7 +17,7 @@
command: # noqa 301
cmd: "dig gw.example.com @127.0.0.1"
register: a_dig
- failed_when: "'gw.example.com.\t\t3600\tIN\tA\t192.168.1.1' not in a_dig.stdout"
+ failed_when: "'gw.example.com.\t\t3600\tIN\tA\t10.0.0.1' not in a_dig.stdout"
- name: Check for NS record
command: # noqa 301
diff --git a/tasks/main.yml b/tasks/main.yml
index 68af1d5..d6a9af6 100644
--- a/tasks/main.yml
+++ b/tasks/main.yml
@@ -42,17 +42,17 @@
notify:
- reload-nsd
-- name: Create DNS reverse zonefiles from template
- template:
- src: zone.reverse.j2
- dest: "{{ nsd_zones_dir }}/{{ item.key }}.reverse"
- mode: 0644
- owner: root
- group: "{{ nsd_groupname }}"
- validate: "nsd-checkzone {{ item.value.ip_range | unbound_revdns }} %s"
- with_dict: "{{ dns_zones }}"
- notify:
- - reload-nsd
+# - name: Create DNS reverse zonefiles from template
+# template:
+# src: zone.reverse.j2
+# dest: "{{ nsd_zones_dir }}/{{ item.key }}.reverse"
+# mode: 0644
+# owner: root
+# group: "{{ nsd_groupname }}"
+# validate: "nsd-checkzone {{ item.value.ip_range | unbound_revdns }} %s"
+# with_dict: "{{ dns_zones }}"
+# notify:
+# - reload-nsd
- name: Flush handlers as listen addresses can conflict with unbound
meta: flush_handlers
diff --git a/templates/nsd.conf.j2 b/templates/nsd.conf.j2
index ff5b39f..93c2a14 100644
--- a/templates/nsd.conf.j2
+++ b/templates/nsd.conf.j2
@@ -24,8 +24,8 @@
name: {{ key }}
zonefile: {{ key }}.forward
-zone:
- name: {{ value.ip_range | unbound_revdns }}
- zonefile: {{ key }}.reverse
+# zone:
+# name: {{ value.ip_range | unbound_revdns }}
+# zonefile: {{ key }}.reverse
{% endfor %}