Networking Homelab
One gateway to rule them all: Nginx Proxy Manager on Proxmox
Clean domain names and HTTPS for every homelab service through a single entry point, with a wildcard DNS record and a local certificate authority.
- Nginx Proxy Manager
- Docker
- mkcert
- iptables
The homelab IP nightmare
Once a homelab passes three services, raw addresses stop scaling. Jellyfin was on 192.168.1.14:8096, Technitium on 192.168.1.11:5380, NPM's own UI on :81, Proxmox on :8006. Try explaining that to a family member, or remembering it on your phone two months later.
A reverse proxy fixes this. It listens on ports 80 and 443, reads the domain name in each request and forwards it to the right backend. jellyfin.home.lan instead of an IP and a port. Since every request now goes through one place, that place can also terminate TLS, block common exploits and put access lists in front of admin pages.
Picking the tool
Four names come up in every "which reverse proxy?" thread:
| Tool | Web UI | Best for | Downside |
|---|---|---|---|
| Nginx Proxy Manager | Yes | Homelabs, learning | Limited to what the UI exposes |
| Traefik | Read-only dashboard | Docker / Kubernetes | Label-based config, steeper curve |
| Caddy | No | Simple automatic HTTPS | Config file only |
| HAProxy | No | Load balancing at scale | Overkill for a single homelab |
I went with NPM. Adding a service takes thirty seconds in the UI and it idles around 150 MB of RAM in a 512 MB container. For a lab meant to teach me things rather than eat my weekends, that is the right trade. (I used HAProxy later for NexiCloud, where load balancing was the point.)
Network layout
The Proxmox host has two relevant bridges:
- vmbr0: bridged to the ISP box on
192.168.2.0/24, where the home devices live. - vmbr1: internal only,
192.168.1.0/24, where every service lives.
The host routes and filters between them. LAN devices can only reach a service through the host's firewall rules, which is cheap segmentation and makes future filtering trivial.
Step 1: the container
NPM does not need a VM. An unprivileged LXC container with Docker inside is lighter and boots in about a second. nesting=1 is required for Docker to run inside LXC.
pct create 112 local:vztmpl/debian13.tar.zst \
--hostname delta --memory 512 --cores 1 \
--net0 name=eth0,bridge=vmbr1,ip=192.168.1.12/24,gw=192.168.1.1 \
--rootfs local-lvm:4 --unprivileged 1 --features nesting=1 \
--onboot 1 --start 1My containers are named after Greek letters. The Proxmox host is alpha, the proxy is delta.
Step 2: Docker and NPM
apt update && apt install -y curl ca-certificates
curl -fsSL https://get.docker.com | sh
mkdir -p /opt/npm && cd /opt/npmservices:
npm:
image: jc21/nginx-proxy-manager:latest
container_name: npm
restart: unless-stopped
ports:
- "80:80" # HTTP
- "443:443" # HTTPS
- "81:81" # admin UI
volumes:
- ./data:/data
- ./letsencrypt:/etc/letsencryptdocker compose up -d
Then open http://192.168.1.12:81. Older NPM releases ship with admin@example.com / changeme and force a change at first login; recent ones ask you to create the admin account on the first visit.
Step 3: bridging the two networks
My laptop is on 192.168.2.0/24, NPM is on 192.168.1.12. The host catches ports 80 and 443 on its LAN interface and rewrites the destination to NPM (DNAT). At the time I did it with iptables:
iptables -t nat -A PREROUTING -i vmbr0 -p tcp --dport 80 -j DNAT --to-destination 192.168.1.12:80
iptables -t nat -A PREROUTING -i vmbr0 -p tcp --dport 443 -j DNAT --to-destination 192.168.1.12:443
iptables -t nat -A POSTROUTING -s 192.168.1.0/24 -o vmbr0 -j MASQUERADEThese rules have since moved into a single nftables file; see From a pile of iptables rules to one nftables file.
Step 4: wildcard DNS
A reverse proxy needs DNS that points every name at it. My Technitium server holds a home.lan zone with a wildcard record:
Text version
*.home.lan → 192.168.2.100 Proxmox host, LAN side
│ DNAT :443
▼
192.168.1.12 NPM, reads the Host header
│
▼
192.168.1.14:8096 JellyfinThat wildcard is the whole trick. Every subdomain resolves to the same address and NPM picks the backend from the Host header. Adding a service needs no DNS change at all.
Step 5: wiring up a service
- Hosts → Proxy Hosts → Add Proxy HostThe button is top right.
- Fill in the Details tabDomain
zeta.home.lan, schemehttp(NPM handles TLS), forward IP192.168.1.14, port8096. Enable Block Common Exploits, and Websockets Support because Jellyfin needs it for playback controls. - Save and testOpen
https://zeta.home.lan. That is the whole routine for every future service.
HTTPS without Let's Encrypt
Let's Encrypt cannot issue certificates for home.lan: it has no way to validate a name that only exists on my network. For local-only services I use mkcert, which creates a personal certificate authority and issues certificates trusted by every device that installs its root.
winget install FiloSottile.mkcert
mkcert -install # adds the root CA to the Windows trust store
mkcert "*.home.lan" home.lan # one wildcard cert for the whole zoneUpload _wildcard.home.lan+1.pem and its -key.pem under SSL Certificates → Custom, select it on each proxy host and enable Force SSL. On phones, install the root CA from mkcert -CAROOT as a trusted certificate. Every service then shows a padlock with no warnings.
What sits behind it
Jellyfin: films, series and music for every device on the LAN.
Technitium admin: DNS, DHCP and blocklists.
NPM itself. The proxy proxies its own admin UI.
Proxmox, with Websockets on so the noVNC console works.
Lessons learned
One wildcard beats per-service records
I started with an A record per service, then found that specific records override the wildcard, and some pointed at the wrong IP. One * record is enough; let NPM do the routing.
DNS bugs hide in client settings
Windows had four DNS servers listed and mine was third, only consulted when the first two timed out. Force the resolver on the interface until the setup is stable.
Segmentation is cheap insurance
Keeping services on vmbr1 costs a few firewall rules and means nothing is reachable without going through the host first.
Local HTTPS is worth five minutes
mkcert removes browser warnings for good. There is no reason to run internal services over plain HTTP once you know the trick.
What came next
NPM became the single entry point and the pattern for adding services has not changed since. The WireGuard VPN followed, so the same names work from outside. Access lists for the admin UIs and SSO in front of dashboards without their own login are still on the roadmap.