Added config support

This commit is contained in:
Connor Johnstone
2026-03-18 15:14:32 -04:00
parent ff41233a96
commit 32b4b533c0
11 changed files with 381 additions and 259 deletions

View File

@@ -58,11 +58,13 @@ async fn main() -> anyhow::Result<()> {
let bind = format!("{}:{}", config.web.bind, config.web.port);
tracing::info!(bind = %bind, "starting server");
let config_path = cli.config.clone();
let state = web::Data::new(AppState {
db,
mb_client,
search,
config,
config: std::sync::Arc::new(tokio::sync::RwLock::new(config)),
config_path: config_path,
tasks: TaskManager::new(),
});