fix(resolvers): disable systemd-resolved stub listener instead of masking

systemd-resolved must run for host DNS (nss/resolv.conf), but its stub
listener on 127.0.0.53:53 conflicts with Unbound's bind to 0.0.0.0:53.

Replace masking with DNSStubListener=no dropin + static resolv.conf
pointing to 1.1.1.1 and 9.9.9.9, so the host can resolve without
occupying port 53.
This commit is contained in:
Graham McIntire 2026-07-24 11:17:33 -05:00
parent 3b9507e5c4
commit 28e119cee2
No known key found for this signature in database
GPG key ID: F4ABF488E6029E59
2 changed files with 26 additions and 4 deletions

View file

@ -18,6 +18,13 @@ storage:
overwrite: true
contents:
inline: flatcar-resolver1
- path: /etc/resolv.conf
mode: 0644
overwrite: true
contents:
inline: |
nameserver 1.1.1.1
nameserver 9.9.9.9
- path: /etc/systemd/network/00-eth0.network
mode: 0644
contents:
@ -30,8 +37,8 @@ storage:
[Network]
Address=204.110.191.240/26
Gateway=204.110.191.254
DNS=9.9.9.9
DNS=1.1.1.1
DNS=9.9.9.9
[Address]
Address=2606:1c80::240/64
@ -112,7 +119,11 @@ storage:
systemd:
units:
- name: systemd-resolved.service
mask: true
dropins:
- name: no-stub.conf
contents: |
[Resolve]
DNSStubListener=no
- name: docker.service
enabled: true
- name: unbound.service

View file

@ -18,6 +18,13 @@ storage:
overwrite: true
contents:
inline: flatcar-resolver2
- path: /etc/resolv.conf
mode: 0644
overwrite: true
contents:
inline: |
nameserver 1.1.1.1
nameserver 9.9.9.9
- path: /etc/systemd/network/00-eth0.network
mode: 0644
contents:
@ -30,8 +37,8 @@ storage:
[Network]
Address=204.110.191.250/26
Gateway=204.110.191.254
DNS=9.9.9.9
DNS=1.1.1.1
DNS=9.9.9.9
[Address]
Address=2606:1c80::250/64
@ -112,7 +119,11 @@ storage:
systemd:
units:
- name: systemd-resolved.service
mask: true
dropins:
- name: no-stub.conf
contents: |
[Resolve]
DNSStubListener=no
- name: docker.service
enabled: true
- name: unbound.service