unarr/internal/config
Deivid Soto 27bee8cdf4 feat(stream): optional per-agent HTTPS listener with hot-reloadable cert
Foundation for direct, valid-cert browser playback (agent-TLS feature) — the
cert broker + DNS are a later phase; this is inert until a certificate exists.

- StreamServer runs a second TLS listener on https_stream_port (default 11819)
  serving the SAME mux as HTTP (11818): same token + CORS gates, no new exposure.
- Certificate is read per-handshake from an atomic holder via tls.Config
  GetCertificate, so a cert issued/renewed asynchronously applies without a
  restart. SetTLSCertificate / LoadTLSCertificateFromFiles / HasTLSCertificate.
- Daemon arms HTTPS only when a cert pair exists at certs/agent.{crt,key} under
  the state dir; without it, no HTTPS port is opened and HTTP + funnel are
  unaffected. Shutdown drains the HTTPS server too.
- config: downloads.https_stream_port (default 11819, 0 = disabled).

Tests: real TLS handshake + hot-install (no-cert handshake fails, install →
200), disabled path, missing-cert load error.
2026-06-01 13:03:35 +02:00
..
config.go feat(stream): optional per-agent HTTPS listener with hot-reloadable cert 2026-06-01 13:03:35 +02:00
config_test.go feat(seeding): wire seed ratio/time lifecycle into the torrent daemon 2026-06-01 10:30:39 +02:00
config_validate_test.go feat: initial commit — unarr CLI 2026-03-28 11:29:42 +01:00
paths.go feat: initial commit — unarr CLI 2026-03-28 11:29:42 +01:00
paths_test.go fix(lint): exclude common fire-and-forget patterns from errcheck 2026-03-30 23:34:36 +02:00