Two related gaps on the headless kiosk: no way to restart the wall short
of a full reboot, and no way to see why a stream keeps flapping (the
daemon's stderr goes to sway on tty1, and mpv's stderr was discarded).
Restart in place:
- `rtsp-streamer restart` sends a control-socket command; the daemon
tears down its mpv children and syscall.Exec's the on-disk binary.
Same PID, same parent (sway), same env — keeps WAYLAND_DISPLAY/
SWAYSOCK and comes back up on the new binary, no reboot. Handles the
os.Executable() "(deleted)" sentinel from make install's rename.
- sway config now launches the daemon in a relaunch loop, so a crash (or
the restart) auto-recovers instead of leaving a black screen.
- `make deploy` now does `install` + `restart` instead of restarting
getty@tty1 (which left stale duplicate sessions and forced reboots).
Retrievable logs:
- New internal/logbuf ring; the daemon tees slog output into it and
serves the tail over the socket via `rtsp-streamer logs [-n N]` —
readable over SSH, no file wrangling, no reboot.
- Capture the tail of each mpv's stderr and log its last line when the
process exits, so "mpv exited, will restart" now carries the reason
(connection refused, unsupported codec, 401, ...). This is the
diagnostic for a single tile going unhealthy repeatedly.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
ldflags inject version, commit, and build date; a version subcommand
also reports go version and platform. Ends the which-binary-is-this
guessing after deploys.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
mpv 0.35 rejects --auto-window-resize, which crash-looped every player.
Drop that flag and re-assert each tile geometry on a 1s timer in the
daemon, overriding mpv auto-resize on any mpv version.
Add make install (auto-sudo, native build + copy to /usr/local/bin)
and make deploy (install + restart the kiosk getty unit).
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>