Tailscale DNS: Take your Local Domains with you NOW
Table of Contents
Introduction
This tutorial will guide you through the process of configuring Tailscale to use your local DNS server, enabling you to access a local domain while on the go. We will specifically create a domain called adguard.home
that points to your AdguardHome web page using Nginx Proxy Manager. This setup allows for seamless access to your self-hosted services, even when you're not on your home network.
Step 1: Understand How DNS Works on Tailscale
Before setting up your DNS, it's important to understand how Tailscale manages DNS requests. Tailscale allows you to specify a DNS server for devices on your tailnet, enabling them to resolve local domain names. Here’s what you need to know:
- Tailscale directs DNS queries to the server you specify.
- You can use your own self-hosted DNS server (like AdguardHome) to resolve local domains.
- This configuration ensures that your local domain remains accessible from anywhere.
Step 2: Set Up AdguardHome
To create a DNS record for your local domain, you need to have AdguardHome set up. If you haven’t done this yet, follow these steps:
- Install AdguardHome on your server or Raspberry Pi.
- Follow the installation guide specific to your operating system.
- Access the AdguardHome web interface using its IP address in your browser.
- Configure your DNS settings:
- Navigate to the 'DNS settings' section.
- Add a new DNS record for
adguard.home
pointing to the internal IP of your AdguardHome instance.
Step 3: Create a Proxy Host with Nginx Proxy Manager
Next, you will create a proxy host in Nginx Proxy Manager to route traffic to AdguardHome. Follow these steps:
- Log in to Nginx Proxy Manager.
- Navigate to the 'Proxy Hosts' section.
- Click on 'Add Proxy Host':
- Domain Names: Enter
adguard.home
. - Scheme: Select
http
orhttps
based on your setup. - Forward Hostname / IP: Enter the internal IP of your AdguardHome server.
- Forward Port: Use the port number that AdguardHome is listening on (default is 80).
- Domain Names: Enter
- Save the configuration.
Step 4: Configure Tailscale to Use Your DNS Server
Now, you’ll configure Tailscale to utilize your newly created DNS settings:
- Log in to your Tailscale admin console.
- Go to the 'DNS' settings page.
- Add your AdguardHome server’s IP address as a DNS server.
- This will allow Tailscale clients to resolve
adguard.home
to the correct address.
- This will allow Tailscale clients to resolve
- Save changes.
Step 5: Test Your Configuration
After completing the setup, it’s important to verify that everything is working correctly:
- Connect a device to your Tailscale network.
- Open a web browser.
- Type
http://adguard.home
in the address bar. - Check if it redirects you to your AdguardHome interface.
Conclusion
You have successfully configured Tailscale to use your local DNS with the domain adguard.home
, allowing you to access your AdguardHome web page from anywhere. Remember to keep your DNS server running and verify your settings if you encounter any access issues. This setup not only enhances your remote access to local services but also maintains the convenience of using familiar domain names. For further learning, consider exploring additional configurations with Nginx Proxy Manager or improving your DNS setup with more advanced features.