January 6, 2026
Regulating internet traffic with my own Adguard Home DNS server
The first container i started once i had my home server installed with Docker was my Adguard Home instance. I saw the dashboard of a friend’s while he showed me all the blocked traffic of devices in his network that were trying to track his online activity. Of course i hurried to get this running in my home LAN.
I have found it extremely satifying to block requests meant for tracing my online presence or just unneccessary traffic. For example, I saw logs.netflix.com queries from my LG smart tv when i did’nt even open the Netflix app. So nice to see that getting blocked. Also saw a lot of wpad dns requests from my windows 11 laptop, which i could turn off, making my LAN traffic cleaner. I’ll write a blog post on how to stop wpad traffic soon.
Haven’t really looked into the different blocklists, something for the near future…
The Process
Make sure you have docker and docker compose installed.
At the end of this page you’ll find the compose.yaml i used. It includes labels for the Traefik reverse proxy which is explained in this blog post. Copy and save the contents to a compose.yaml file on your server, then run
docker compose up -dto start the container in the background. Now test if it runs correctly by visiting the dashboard at port 3000 on your server IP.
Next, we need to set the IP address of our server as the DNS server on our router. Login to your router and change the DNS to be static and using your server IP. In my case, it took some time for my devices to use the new DNS server, at most a day (the default DHCP lease time). Some devices i switched manually because i got impatient.
Now you should be able to see queries being processed or blocked by your very own DNS server!!
Compose.yaml
name: adguardhome
services:
adguardhome:
image: adguard/adguardhome
container_name: adguard
networks:
- proxy # the docker network used by my Traefik reverse proxy
ports:
- 53:53/tcp # plain dns over tcp
- 53:53/udp # plain dns over udp
volumes:
- /opt/docker/adguardhome:/opt/adguardhome/conf # app configuration
- /opt/docker/adguardhome:/opt/adguardhome/work # app working directory
labels: #labels for Traefik config
- traefik.enable=true
- traefik.http.routers.adguard.rule=Host(`$YOUR_ENDPOINT`)
- traefik.http.routers.adguard.entrypoints=websecure
- traefik.http.routers.adguard.tls=true
- traefik.http.services.adguard.loadbalancer.server.port=3000 # port set so traefik knows where to send dashboard traffic
networks:
proxy:
external: true