Skip to main content

schedr_config/
lib.rs

1//! Configuration loading and validation for schedr (TOML file, environment variables, flags).
2//!
3//! See archive/PROJECT.md, Configuration: one TOML file and/or `SCHEDR_CONFIG__*` environment
4//! variables mirroring its structure, with `SCHEDR_DAG_PATH` / `SCHEDR_SCRIPT_PATH` as short
5//! aliases; precedence flags > environment > file. Loading is pure: the caller reads the file
6//! and the process environment and passes them in.
7
8pub mod config;
9pub mod loader;
10pub mod masked;
11pub mod roots;
12pub mod sources;
13pub mod units;
14
15pub use config::{
16    AuthMode, AuthSection, Config, DagsSection, DatabaseSection, Interpreter, LogFormat,
17    LogSection, MappingSection, OpsSection, ScriptsSection, TlsMode, TlsSection, config_schema,
18    url_has_password,
19};
20pub use loader::{ConfigError, load};
21pub use roots::{PathList, Root, RootError};
22pub use sources::{ConfigFile, FileSource, Override, OverrideValue, SourceError, config_file};
23pub use units::{
24    MemoryReserve, UnitError, format_duration, format_reserve, format_size, parse_duration,
25    parse_reserve, parse_size,
26};