Add log rotation to server & UI improvements (#157)

This commit is contained in:
Andras Schmelczer 2025-11-02 17:52:04 +00:00 committed by GitHub
parent 2b9d77d165
commit cd57ea6682
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
19 changed files with 508 additions and 38 deletions

View file

@ -13,7 +13,7 @@ mod responses;
mod update_document;
mod websocket;
use std::{ffi::OsString, time::Duration};
use std::time::Duration;
use anyhow::{Context as _, Result, anyhow};
use auth::auth_middleware;
@ -42,12 +42,12 @@ use tracing::{Level, info_span};
use crate::{
app_state::AppState,
config::server_config::ServerConfig,
config::{Config, server_config::ServerConfig},
errors::{client_error, not_found_error},
};
pub async fn create_server(config_path: Option<OsString>) -> Result<()> {
let app_state = AppState::try_new(config_path)
pub async fn create_server(config: Config) -> Result<()> {
let app_state = AppState::try_new(config)
.await
.context("Failed to initialise app state")?;