Skip to content

Names and Certificates

You'll put every service in the lab behind one reverse proxy, give each a name instead of a port number, and get a real padlock in the browser without opening anything to the internet.

About

Once you have five services, nobody in the house remembers which one is port 8096. A reverse proxy like Caddy, Traefik or Nginx Proxy Manager listens on one address and sends each name to the right container, and it can fetch a certificate for each name so the browser stops warning your family. The trick for a lab that isn't on the public internet is a DNS challenge with a domain you own, which is about ten dollars a year, or your own small certificate authority installed on each device. Either way the names resolve inside the house only and nothing here gets opened to the world. Expect a week of reading and an evening of doing, and expect the first certificate to fail on a typo.

At a glance

Per requirement
35 XP
Completion bonus
300 XP
Requirements
6
Takes
Two or three weekends
Skill level
Intermediate (months of practice)
Cost
Free
Supplies
You need some
Where
At home
Other people
With other people
Locked for now
Earn two more Uncommon badges in Homelab & Hardware to open this one. Log in to see how far along you are.

Requirements

  1. 1
    Pick a domain for the lab and make three names resolve inside the house. A domain you own with a subdomain for home, or an internal name with your own certificate authority. Point the names at the box that will run the proxy, through your own resolver or a wildcard record. Take a screenshot of all three names resolving from a laptop. Photo
  2. 2
    Run a reverse proxy in front of two services on plain HTTP. One container, and each service gets a name that the proxy routes by hostname. Take a screenshot of both services opening by name with no port number in the address bar. Photo
  3. 3
    Get a trusted certificate for one name. A DNS challenge through your registrar's API is the route for a real domain, and Caddy and Traefik both do it in a few lines. For an internal domain, mkcert or step-ca makes the certificate and you install the root on your laptop. Take a screenshot of the padlock with the certificate details open, showing who issued it. Photo
  4. 4
    Move every service behind the proxy and close the direct ports. Bind each container to localhost or to the Docker network so only the proxy can reach it. Then try the old port from another device and watch it refuse. Film the old port failing and the name working. Video
  5. 5
    Get the padlock on a phone that isn't yours. A family member's phone on the house Wi-Fi opens a service with no warning. If you went the internal route, you'll be installing your root certificate on their phone, with their permission, and that's the honest cost of that route. Take a photo of their phone showing the padlock. Photo
  6. 6
    Write the one-page map of names to services and pin it next to the shelf. For each name: the container, the port behind the proxy, where the certificate comes from and when it renews. This page is what you'll reach for on Rebuild Day. Take a photo of the page in place. Photo