pub struct Config {
pub manifest: PathBuf,
pub bind: String,
pub workers: Option<usize>,
pub cdn_base_url: Option<String>,
pub fallback_dir: Option<PathBuf>,
pub worker_entry: PathBuf,
pub sources_config: Option<PathBuf>,
pub session_secret_env: Option<String>,
pub session_cookie: String,
pub login_url: Option<String>,
pub cache_capacity: usize,
}Fields§
§manifest: PathBufLocal path to manifest.json (required).
bind: StringBind address for the HTTP listener.
workers: Option<usize>Number of Bun workers to spawn (default = num_cpus / 2, min 1).
cdn_base_url: Option<String>CDN base URL for Mode 1 redirect dispatch (e.g. https://cdn.yah.dev).
When set, Mode 1 routes 302-redirect to {cdn_base_url}{path}.
fallback_dir: Option<PathBuf>Local dist/ directory for Mode 1 fallback (when CDN is not configured).
worker_entry: PathBufPath to the mesofact-worker entry script (bun entrypoint).
sources_config: Option<PathBuf>Path to mesofact.config.toml. Read for source generation tokens
(cache-key input 6). Missing file → generations resolve to a placeholder.
session_secret_env: Option<String>Env var holding the HMAC key for CookieSessionResolver. When set,
Mode 2 sessions resolve from the session cookie; when unset, sessions
are disabled (requires: ["user"] routes always redirect/401).
Session cookie name (default mesofact_session).
login_url: Option<String>Login URL for requires: ["user"] routes with no session. The proxy
302s here with ?next=<original-url>. Unset → 401 instead.
cache_capacity: usizeMode 2 LRU response-cache capacity (entries).
Implementations§
Trait Implementations§
Source§impl Args for Config
impl Args for Config
Source§fn augment_args<'b>(__clap_app: Command) -> Command
fn augment_args<'b>(__clap_app: Command) -> Command
Source§fn augment_args_for_update<'b>(__clap_app: Command) -> Command
fn augment_args_for_update<'b>(__clap_app: Command) -> Command
Command so it can instantiate self via
FromArgMatches::update_from_arg_matches_mut Read moreSource§impl CommandFactory for Config
impl CommandFactory for Config
Source§impl FromArgMatches for Config
impl FromArgMatches for Config
Source§fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>
fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>
Source§fn from_arg_matches_mut(
__clap_arg_matches: &mut ArgMatches,
) -> Result<Self, Error>
fn from_arg_matches_mut( __clap_arg_matches: &mut ArgMatches, ) -> Result<Self, Error>
Source§fn update_from_arg_matches(
&mut self,
__clap_arg_matches: &ArgMatches,
) -> Result<(), Error>
fn update_from_arg_matches( &mut self, __clap_arg_matches: &ArgMatches, ) -> Result<(), Error>
ArgMatches to self.Source§fn update_from_arg_matches_mut(
&mut self,
__clap_arg_matches: &mut ArgMatches,
) -> Result<(), Error>
fn update_from_arg_matches_mut( &mut self, __clap_arg_matches: &mut ArgMatches, ) -> Result<(), Error>
ArgMatches to self.