With consolidating and upgrading my home network I’m moving Pi-hole from a stand-alone Raspberry Pi to running under Docker on my Synology DS1019+ running DiskStation Manager (DSM) v6.2.3.
This was a little bit confusing at first as the web management UI would work, but DNS queries weren’t getting answered. This ended up being caused by the bonded network interface, which is
ovs_bond0 instead of the normal default of
Using the official Pi-hole Docker image, set to run with Host networking (Use the same network as Docker host in the Synology UI), setting or changing the following variables will set up Pi-hole work from first boot, configured to:
- Listen on
ovs_bond0(instead of the default
- Answer DNS queries on the same IP as DSM (
- Run the with the web-based management interface on port 8081 with password
- Send internal name resolutions to the internal DNS/DHCP server at
- Set the displayed temperature to Farenheit and time zone to
- Listen for HTTP requests on
http://diskstation.internal.example.com:8081along side the default
Additionally, setting up volumes for
/etc/pihole/ will ensure changes to the UI persist across restarts and container upgrades. I do this as shown here:
Note: If you stop the Pi-hole container, clear out the contents of these directories, and then restart the container, Pi-hole will set itself up again from the environment variables. This allows tweaking the variables without recreating the container each time.