fix(config): tolerate a not-yet-generated auth.secret_file
dad15c0 · hanna committed on 2026-07-26
The example config sets `auth.secret_file` and documents it as "generated on
first run", but config load hard-read the file and errored when it was missing —
so a fresh container (empty volume) crash-looped with "failed to read secret
file" before `ensure_secret` could create it. Treat a NotFound secret_file as
absent (the server generates and persists one); a present-but-unreadable file
stays a hard error, and a missing mail password_file still errors.
Also create /var/lib/fabrica owned by the fabrica user in the image so first-run
generation (signing secret, SQLite database, repos) can actually write to it.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Signed by hannaSSH key fingerprint: SHA256:4g9cWhkAAw8gwqhJUcVbSnGEvdGwklW+1Aa/fMUu59k