diff --git a/playbooks/network_services/dns.yml b/playbooks/network_services/dns.yml index eda0578..a66fe4a 100644 --- a/playbooks/network_services/dns.yml +++ b/playbooks/network_services/dns.yml @@ -39,13 +39,17 @@ - name: allow access to a firewall ansible.posix.firewalld: - service: dns + service: "{{item}}" permanent: true state: enabled immediate: true + loop: + - "dns" + - "dns-over-tls" + - "mdns" - name: start the bind service ansible.builtin.service: name: named - state: started + state: restarted enabled: true diff --git a/templates/homelab.local.zone.j2 b/templates/homelab.local.zone.j2 index e1428ed..d9227a1 100644 --- a/templates/homelab.local.zone.j2 +++ b/templates/homelab.local.zone.j2 @@ -1,12 +1,14 @@ $TTL 8h @ IN SOA ns1.homelab.local. hostmaster.homelab.local. ( - 2024100607 ; serial number + 2022070601 ; serial number 1d ; refresh period 3h ; retry period 3d ; expire time 3h ) ; minimum TTL -;www IN A 192.168.2. -@ IN NS ns1.homelab.local. + IN NS ns1.homelab.local. + IN MX 10 mail.homelab.local. + +www IN A 192.168.2.1 ns1 IN A 192.168.2.236 -;mail IN A 192.0.2.20 +mail IN A 192.168.2.1