Files
k3s-cluster/pihole/unbound/unbound.conf
2026-06-28 19:08:04 +02:00

45 lines
1.2 KiB
Plaintext

server:
# Listen on all interfaces so the kubelet's liveness/readiness probes
# (which connect to the pod IP, not 127.0.0.1) can reach unbound.
# No Service exposes port 5335, so it stays cluster-internal; pihole
# still forwards to 127.0.0.1#5335 which works because 0.0.0.0 covers
# loopback.
interface: 0.0.0.0
port: 5335
# IPv4 only for simplicity
do-ip4: yes
do-udp: yes
do-tcp: yes
do-ip6: no
prefer-ip6: no
# Recursive resolver: do not use any forwarders, start from the root servers
root-hints: "/opt/unbound/etc/unbound/root.hints"
# DNSSEC / hardening
harden-glue: yes
harden-dnssec-stripped: yes
harden-referral-path: yes
# Performance / privacy
prefetch: yes
prefetch-key: yes
qname-minimisation: yes
aggressive-nsec: yes
edns-buffer-size: 1232
num-threads: 1
so-rcvbuf: 1m
# RFC1918 / link-local addresses should never come back from the internet
private-address: 10.0.0.0/8
private-address: 172.16.0.0/12
private-address: 192.168.0.0/16
private-address: 169.254.0.0/16
private-address: fd00::/8
private-address: fe80::/10
# Hide identity / version
hide-identity: yes
hide-version: yes