Layered configuration loader.
Minimal env-var loader for the Gateway. Adds layered file (yaml/toml) and CLI-flag merging in later iterations when those callers exist.
Reading
use tt_config::Config;
let cfg = Config::from_env().expect("env vars valid");
Conventions
- Required vars return [
ConfigError::Missing] when absent. - Optional vars return
Nonewhen absent andSome(_)when present. - Parse failures (e.g.
PORT="abc") return [ConfigError::Parse].