I built WireHole to put a VPN and a filtering DNS resolver in one Compose project. A phone can use the same resolver at home and on mobile data. WireGuard gets the phone’s DNS requests to the server. Pi-hole decides which domains to block, and Unbound resolves and caches the queries that pass through. Docker Compose keeps those three services together. WireHole on GitHub

What goes through the tunnel?#

With a split tunnel, the phone can send DNS queries to Pi-hole while a video stream goes straight over its usual connection. With a full tunnel, the stream goes through the VPN server too. That choice matters on a cloud VM where outbound traffic counts toward a monthly allowance.

If you already run WireHole#

The 2026 rewrite changed the layout on disk. A phone already paired with the VPN still expects its old keys and endpoint. The migration script preserves those along with Pi-hole’s data. After migrating, connect an existing device and look for a recent handshake in the diagnostic output. Upgrade guide

My 2020 Terraform walkthrough records the original Oracle Cloud setup. For a fresh installation, use the current setup instructions.