add unbound

This commit is contained in:
aykhans committed 2026-11-04 16:32:27 +00:00
1 parent 8e45c96dec
commit 810d7d96f0
3 files changed
+74

No files matched your search

+4
View File
@@ -0,0 +1,4 @@
FROM alpine:3
RUN apk add --no-cache unbound dnssec-root
USER unbound
ENTRYPOINT ["unbound", "-d", "-c", "/etc/unbound/unbound.conf"]
+25
View File
@@ -0,0 +1,25 @@
networks:
caddy:
name: caddy
driver: bridge
external: true
services:
unbound:
build: .
container_name: unbound
restart: unless-stopped
read_only: true
cap_drop:
- ALL
security_opt:
- no-new-privileges:true
volumes:
- ./unbound.conf:/etc/unbound/unbound.conf:ro
networks:
- caddy
logging:
driver: "json-file"
options:
max-size: "100m"
max-file: "3"
+45
View File
@@ -0,0 +1,45 @@
server:
username: ""
chroot: ""
directory: "/etc/unbound"
pidfile: ""
use-syslog: no
logfile: ""
verbosity: 1
log-queries: no
log-replies: no
# Plain HTTP/2 DoH for Caddy only. The public path lives in caddy/.env.
interface: 0.0.0.0@8053
https-port: 8053
http-notls-downstream: yes
http-endpoint: "/dns-query"
access-control: 0.0.0.0/0 refuse
access-control: 172.16.0.0/12 allow
do-ip4: yes
do-ip6: no
do-udp: yes
do-tcp: yes
trust-anchor-file: "/usr/share/dnssec-root/trusted-key.key"
hide-identity: yes
hide-version: yes
qname-minimisation: yes
harden-glue: yes
harden-dnssec-stripped: yes
harden-below-nxdomain: yes
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: fc00::/7
private-address: fe80::/10
num-threads: 2
msg-cache-size: 64m
rrset-cache-size: 128m
prefetch: yes
prefetch-key: yes
serve-expired: yes
serve-expired-ttl: 86400
serve-expired-client-timeout: 1800