Host/domain ambiguity
In the process of debugging Jellyfin and Chromecast, I ended up splitting my Traefik instance in two (one per host). However, there are still a few instances where the Traefik instance isn’t on the same IP as the service it’s providing.
unifi.home.lan
to10.0.0.1:8443
proxmox.home.lan
to10.0.0.10:8006
nanoleaf.home.lan
to10.0.0.21:16021
There are some other examples, but the pattern here is devices that expose their data on non-standard ports.
Maybe I’m overcomplicating things here, but it’s frustrating to know that the device one reaches
through HTTP/HTTPS isn’t the same one reaches through ICMP or any other protocol. ping unifi.home.lan
will actually be pinging system-apps, not unifi. Misleading!
Two solutions come to mind:
- I could try to get Traefik to route all traffic based on the requested domain name, but I’m not sure if Traefik is capable of that. Would that play well with UDP? With SSH? Would that drastically overcomplicate my Traefik setup?
- Alternatively, I could set up a second domain (say
hosts.lan
) and map these domains to the correct IPs, whilehome.lan
continues to act as an HTTP/HTTPS shortcut. For example:unifi.home.lan
to10.0.0.11
where Traefik routes it to10.0.0.1:8443
unifi.hosts.lan
directly to10.0.0.1
Given the expected investigation time the first would require, I’ve opted for the second approach. I’m still unsure if this is absolutely necessary or if mDNS would be sufficient, but I can always revisit this later.