Warn when the detected advertised address is on a virtual interface

make url, make qr and make cert now print a warning (with candidate
addresses of real interfaces) when the address found through the default
route belongs to a tunnel or bridge, which the tablet cannot reach and
which the HTTPS certificate would wrongly cover. Silent when
server.advertise_host or an explicit server.host is set.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
Denis Defolie
2026-10-30 15:31:07 +01:00
parent 97cf2afb53
commit 75a7e108d7
6 changed files with 174 additions and 4 deletions
+2 -1
View File
@@ -66,7 +66,8 @@ Run every `make` command **from the project folder** (the one containing the `Ma
- **PC with a VPN (WireGuard, Proton VPN…): set `advertise_host`.** `make url`, `make qr` and `make cert` work out
the PC's address from the default route; with an active VPN that route goes through the tunnel (`wg0`, `tun0`,
`proton0`…; for example `10.2.0.2`), so the advertised address cannot be reached by the tablet. The HTTPS
certificate would also be issued for that wrong address. Before `make cert`, put the PC's address **on the local
certificate would also be issued for that wrong address. These three commands print a warning (with candidate
addresses) when the detected address belongs to a virtual interface (tunnel, Docker bridge). Before `make cert`, put the PC's address **on the local
network**, outside any tunnel, in `~/.config/mediadeck/config.toml`:
```toml