stratum-node-config
[!WARNING] Pre-release (
0.1.0-alpha). The API, thestratum.tomlschema and the public-hash encoding may change before 0.1.0. Nothing built on it has been deployed yet.
The configuration library of a Stratum node. It works on text and values only: no filesystem, network, clock, environment or secret resolution.
- One schema table. Every field of
stratum.tomlhas a dotted path, a type (string, ranged integer, boolean, enum, list of strings or secret reference), a default, a description and an apply class (live,restart,redeploy). Validation, the commented seed document, the typed accessors, the public view and the JSON served by a schema endpoint are all derived from that one table. - Semantic validation. Parsing reports every error, not just the first:
syntax, a missing or unsupported
schema_version, unknown keys, wrong types, out-of-range values, field rules (loopback listen address, HTTPS origin, absolute paths, age recipients) and cross-field conflicts. - Preview. A list of
{path, value}changes becomes, without side effects, the edited TOML (comments and key order preserved), a unified diff, a change list in schema order with secret references redacted, each change's apply class, the strictest class overall, and the validation errors of the result. - Membership and pod limits.
membership.max_tenants,membership.invitations_enabled,membership.invitation_ttl_secs,limits.max_pod_body_bytes,limits.admission_requests_per_minuteandlimits.min_pod_free_bytes, all applied live, with typed accessors. - Public hash. SHA-256 over a documented canonical encoding of the effective configuration with secret-reference fields removed, prefixed with a hash-format version.
Example
use ;
Minimum supported Rust version
1.89.
Licence
AGPL-3.0-only. See LICENSE.