How to use docker selfhosted DNS server on phone over Tailscale? reddit / selfhosted ---------------------------------------------------------------------- BunkerMoewe · 2023-11-22 20:33 Hello guys, I'm trying to get Domain Names to work inside my Tailnet. My setup is a Tailscale Docker container running inside a docker network. The DNS server (dnsmasq) is also running inside this docker network. Tailscale uses --advertise-routes=172.18.0.0/16 to expose the docker network and so the DNS server is theoreticly reachable over the Tailnet with the IP 172.18.0.x, but I just cant figure out, how to tell my phone to use this as its DNS server. I would also like to still have another 'real' DNS server configured for my phone, so I dont have to use my selfhosted DNS server for every DNS lookup. From what I could gather already, Private DNS on android is an option, that might work, but when I tried it, I couldnt enter my DNS servers IP address and then, from how I understand it, this is my only DNS server configured for the phone. I hope I could describe my problem as good as possible and someone is able to help me out. :) ---------------------------------------------------------------------- mabernu · 2023-11-22 21:18 I solved that setting up as "exit node" into the phone app a node into tailnet with the dns server configured. I mean, wherever node inside of your tailnet should working against your dns server and you can use it like "exit node". ---------------------------------------------------------------------- MRP_yt · 2023-11-22 22:08 Inside tailscale admin panel, under DNS settings you can specify which DNS server to use. I think by default that option is off. I got my ON and pointing to 192.168.178.136 which is pihole. This options forces every device in tailsnet hit Pihole for DNS . ---------------------------------------------------------------------- BunkerMoewe · 2023-11-22 22:11 Thank you very much. This sounds like exactly what I'm lookin for ---------------------------------------------------------------------- MRP_yt · 2023-11-22 22:22 No probs. I been using this feature since day one. One thing please note: you can add more then 1 DNS IP address and they will work from top down. Which means if IP in 1st spot fails it will go to 2nd one. In my case if pihole fails to resolve it it fallback to 2nd pihole instant and if that fails 3rd place is for cloudflare 1.1.1.1