Files
vanlink/ha/esphome.container
Andreas WredeandClaude Sonnet 5 8efb8dba5f dns: fixed 1.1.1.1/8.8.8.8 lockdown + scoped mDNS, esphome sibling container
- deploy.conf: DNS_RESOLVERS, always 1.1.1.1/8.8.8.8, never a WAN's own
  DHCP/RA-provided servers (previously whatever Wapana handed out).
- ap/99-van-router-dns.conf: global resolved config (fixed DNS, Domains=~.,
  global MulticastDNS=yes — a prerequisite for any per-link mDNS to work at
  all, not just an on/off toggle).
- failover/60-van-wan-dns: NM dispatcher that strips each WAN's DNS/search-
  domain and disables its mDNS via resolvectl on every connect/lease event
  (NM's own ipv4/ipv6.ignore-auto-dns can't be set as a config-file default —
  confirmed rejected as an unknown key — so this enforces it directly
  instead), retried over ~5s to beat NM's own async DNS commit. Also logs
  what each WAN advertised, never used, to /run/van-wan-dns/.
- ap/21-van-br0.network: MulticastDNS=yes, scoped to the van's own LAN only
  — .local/mDNS now resolves for ESPHome and other LAN devices without
  leaking mDNS onto Wapana/Starlink/cellular.
- dns/: ZeroTier-managed DNS (zt.wrede.pvt) made reproducible — installed
  the official zerotier-systemd-manager package (verified against upstream
  checksums), additive to the above so *.zt.wrede.pvt keeps resolving over
  the overlay independent of WAN.
- ha/esphome.container: ESPHome dashboard as a sibling Podman Quadlet to
  Home Assistant, same host-network/config-volume pattern.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-01 16:09:01 -04:00

36 lines
1.3 KiB
INI

# ESPHome dashboard as a Podman Quadlet, same pattern as homeassistant.container
# (this isn't Home Assistant Supervised, so there's no add-on store — a sibling
# container is the equivalent). Installed by deploy.sh to /etc/containers/systemd/;
# systemd generates esphome.service from it.
#
# Host networking: the dashboard binds :6052 directly (http://10.42.0.1:6052),
# and ESPHome's mDNS-based OTA discovery/flashing of already-provisioned nodes
# needs to see the LAN as the host does — a bridged network would need explicit
# port/mDNS forwarding for the same result.
[Unit]
Description=ESPHome dashboard (Podman container)
Wants=network-online.target
After=network-online.target
[Container]
Image=ghcr.io/esphome/esphome:stable
ContainerName=esphome
Network=host
Volume=/srv/esphome:/config
Environment=TZ=America/Toronto
# Initial flash of a new device needs USB serial access; OTA re-flashes of an
# already-provisioned node don't. Uncomment and set the real path to flash
# over USB (find it with `ls /dev/ttyUSB* /dev/ttyACM*` after plugging the
# device in):
#Volume=/dev/ttyUSB0:/dev/ttyUSB0
#AddCapability=SYS_ADMIN
[Service]
Restart=always
# First start pulls the image; PlatformIO also downloads toolchains on a
# node's first compile — both want a working WAN, not just a fast one.
TimeoutStartSec=900
[Install]
WantedBy=multi-user.target