Skip to content

authority

Modules

  • config - User-level firma.toml reader / writer.
  • prompt - TTY-aware y/N prompt for Authority bootstrap.
  • selection - Resolve AuthoritySelection from CLI args, persisted user config,
  • supervisor - Per-run autostarted Mini Authority: spawn, scrape ready, tee logs,

User-level firma.toml reader / writer.

Path resolution is delegated to the shared firma-config crate so every binary discovers and writes the same firma.toml.

Only the [authority] table is touched by this module today. Persistence is gated by the Y branch of the bootstrap prompt; CLI overrides never rewrite the file.

TTY-aware y/N prompt for Authority bootstrap.

The trait exists so tests can inject canned answers without touching real stdin. The prod impl [StdAuthorityPrompt] uses std::io::IsTerminal on stdin to decide whether interaction is even possible, and reads a single line for the answer.

Resolve AuthoritySelection from CLI args, persisted user config, and the y/N prompt.

Precedence: CLI > persisted > prompt (only when both empty and TTY). Persistence is gated strictly by the Y branch of the prompt — CLI overrides and pre-existing persisted entries do not rewrite the file.

Per-run autostarted Mini Authority: spawn, scrape ready, tee logs, kill on Drop. Mirrors firma-run/src/sidecar/supervisor.rs (FIR-102).