At the time of writing this I have 54 Docker containers running on my home lab Unraid server. I find myself accessing the services I’m running from many machines and quickly realized how impossible it is to memorize not only the IP address I assigned the server the all the ports each service is running on. My goal was to have an easy way to remember string map to each port.

This approach requires you have:

  • a static IP address, which can be obtained many ways
  • DNS name registered

I obtained my static IP address “for free” by leveraging Zerotier as my homelab’s VPN.. For future reference, lets call my Unraid server’s VPN IP address is x.x.x.x.

Next, I registered a DNS name on Namecheap, lets call this name example.com.

Now before I move forward, I swap the Unraid’s UI’s port from 80 to 8080, which can be done in Settings -> Identification -> Management Access in the Unraid application. That way our new Nginx Proxy Manager application can run on port 80. Now we can install the easy to use Nginx Proxy Manager application on our Unraid server and remember use port 80 for this. I suggest using this Docker container which is available in the Unraid App tab.

Now that Nginx Proxy Manager is installed and running, I create two DNS records with my DNS name registrar (Namecheap).

  1. a CNAME Record with host * and value to our domain name example.com
  2. an A Record with host @ and value the-static-ip-of-my-unraid-server

Note: Changes to one’s DNS name records can take up to an hour to take effect

This will map all visits of example.com or even foo.example.com to the Unraid server if we’re on the VPN. This has two useful consequences:

  1. We can use these easy to remember names when we’re not on our home network by connecting to our VPN.
  2. We can route the request to Nginx Proxy Manager and have the easy to remember name be mapped to the hard to remember port.

Now all we have to do is load up Nginx Proxy Manager’s web UI and add records that map a name to a port. For example, I have a Proxy Host that maps pihole.example.com to the Destination of http://example.com:1234, SSL is HTTP only and Access is Public. This works as we’re on our VPN.

And there we have it, we can map easy to remember records to hard to remember port numbers and leverage this outside our home network!