config: stop startup on an invalid DNS or TLS interval #178

Merged
clawbot merged 1 commits from issue-177-interval-validation into next 2026-10-01 22:19:05 +02:00
1 Commits
Author SHA1 Message Date
sneak 49f5552443 config: stop startup on an invalid DNS or TLS interval (closes #177)
check / check (push) Successful in 1m6s
DNSWATCHER_DNS_INTERVAL and DNSWATCHER_TLS_INTERVAL were parsed with
time.ParseDuration and silently replaced by the default when that failed,
so a value like 5 or 1d gave hourly checks with no hint why, and zero or
negative values were accepted. Both now go through parseInterval, which
returns an error naming the variable and the value, and startup stops the
same way it does for invalid targets. An unset or empty variable still gets
its default from setupViper. The three tests that pinned the old fallback
are replaced. The README says what a valid value looks like.

Model: opus-5-5
2026-10-01 20:16:16 +00:00