IMPORTANT: Either use this locally or with a VPN. This project is not meant to be used on a public server.
- Start with a new Ubuntu 22 server.
- Close all ports except 22 TCP for SSH, 53 TCP/UDP for DNS and 80 TCP for the web interface.
- Install Docker.
- Run
sudo sed -r -i.orig 's/#?DNSStubListener=yes/DNSStubListener=no/g' /etc/systemd/resolved.conf
,sudo sh -c 'rm /etc/resolv.conf && ln -s /run/systemd/resolve/resolv.conf /etc/resolv.conf'
andsudo systemctl restart systemd-resolved
. - Clone this repository to
/srv/pihole-unbound
. - Run
sudo docker-compose up -d
in the cloned directory. - Get your web interface password with
sudo docker logs pihole | grep random
. - Check if everything is working by browsing to
http://<your-ip>/admin
and entering the password from the last step.
cd /srv/pihole-unbound && sudo docker-compose down -t 120 && sudo docker-compose pull && sudo docker-compose up -d --remove-orphans && sudo docker image prune