Proxy Management & Cloudflare Tunnels#
What Was Established#
There are multiple layers of proxying available in the homelab, ranging from edge protection (Cloudflare) to local routing (OPNsense/Nginx Proxy Manager).
Nginx Proxy Manager (NPM) Troubleshooting#
- Redirect Loops & Timeouts: Often caused by misconfigured upstream servers or aggressive timeout settings in NPM’s web UI. Resolving a redirect loop may expose underlying connectivity issues that manifest as timeouts.
- Docker Compose Pattern: NPM is deployed with
network_mode: hostto bind directly to host ports (80, 443, 81), bypassing Docker’s NAT for direct host network access. - Verification Steps:
- Check container health:
docker ps | grep nginx-proxy-manager(ensurehealthystatus). - Verify port bindings:
sudo netstat -tulpn | grep :80/:443(requiresnet-toolspackage). - Inspect NPM Web UI: Access at
http://<host-ip>:81to review Proxy Host settings, specifically timeout values and upstream server addresses.
- Check container health:
- Port Conflicts: Use
netstatto identify which container owns a specific port (e.g.,docker-proxyvsnginx: master). In this setup, port 8000 was observed bound todocker-proxy, indicating another service in the compose stack. - Co-located Services: The same Docker Compose stack hosts
cloudflare-ddns(for dynamic IP updates) andnetbird(for mesh networking), requiring careful port management to avoid conflicts.
Key Decisions#
- Use
network_mode: hostfor NPM to simplify port mapping and ensure direct access to host network interfaces. - Rely on
net-tools(netstat) for quick port binding verification in host-networked Docker containers.
Current Configuration#
- Docker Host:
iluvatar@proxy(192.168.1.208) - NPM Web UI:
http://192.168.1.208:81 - Ports: 80 (HTTP), 443 (HTTPS), 81 (NPM Admin UI)
Historical Notes#
- Troubleshooting session from 2025-11-17 resolved a redirect loop that subsequently turned into a timeout issue.
net-toolsinstallation was required to diagnose port bindings on the host.
Open Questions#
- Specific timeout values configured in NPM for upstream services.
- Whether
netbirdorcloudflare-ddnsrequires dedicated port exposure or can share the host network.
Related Pages#
- Cloudflare Integration: SSL & DNS
- OPNsense DMZ Firewall Rules for IoT
- Docker Host Configuration