Hey everyone
,
I’m running two DietPi boards devoted to network duties (Pi-hole, Unbound, Tailscale). My primary node currently handles all reverse-proxy traffic via Nginx Proxy Manager (NPM) in Docker/Portainer and works great, but every reboot means downtime. I’d like to introduce redundancy by spinning up NPM on the secondary node and putting a load-balancer in front.
What I’ve done so far
-
Installed Docker, Compose & Portainer on the secondary Pi.
-
Tried deploying NPM there, but Portainer threw:
failed to bind host port for 0.0.0.0:80 … address already in use -
Discovered that HAProxy, which I had just installed from
dietpi-software, was already listening on :80. -
Removed HAProxy → redeployed NPM → stack came up fine.
The plan
- Sync configs/certs from primary → secondary (thinking cron + rsync).
- Re-install HAProxy (or another LB) to provide a single virtual IP in Pi-hole’s local DNS, then split traffic to whichever NPM is alive.
What I’m unsure about
- Config Sync: Is a simple
rsynccron job the safest way to keep/docker/nginx-proxy-manager(or wherever you store your configs + LetsEncrypt certs) identical between boxes? Any gotchas with live cert renewals? - Load-balancer Choice: Is HAProxy (from DietPi’s repo) the right tool here, or would you recommend something else like Keepalived, Traefik, or even Nginx itself in active-passive?
- Port Conflicts: After HAProxy is back, how do you cleanly avoid the :80/:443 bind clash while still off-loading TLS to NPM?
Would love to hear how others solved this or any best-practice pointers before I break production again. Thanks!