Please share ideas.
I've setup pi-hole and unboud (custom image) with docker. All forks fine, but with workaround. I've added static IP to unbound container because its impossible to add FQDN as custom DNS server.
docker-compose.yml
networks:
....
dns:
name: dns
ipam:
driver: default
config:
- subnet: "192.168.12.0/24"
...
services:
...
pihole:
container_name: pihole
image: pihole/pihole:latest
hostname: home
...
networks:
- main
- dns
...
unbound:
container_name: unbound
image: unbound-alpine
pull_policy: never
networks:
dns:
ipv4_address: 192.168.12.254
....
Dockerfile
FROM alpine:latest
RUN apk add --no-cache unbound
COPY unbound.conf /etc/unbound/unbound.conf
WORKDIR /etc/unbound/
EXPOSE 53
EXPOSE 53/udp
CMD ["unbound", "-c", "/etc/unbound/unbound.conf", "-d"]