diff --git a/src/config.rs b/src/config.rs index 317cb14..4659dce 100644 --- a/src/config.rs +++ b/src/config.rs @@ -23,12 +23,12 @@ const CPUS_RESERVED_FOR_SYSTEM: u32 = 2; #[derive(Debug)] pub struct Config { /// Path to the db for diesel to use - database_path: String, + pub database_path: String, /// Maximum number of workers to use /// A value of 0 makes stuff single-threaded - max_workers: u32, + pub max_workers: u32, /// Minimum number of workers to use - min_workers: u32, + pub min_workers: u32, } #[derive(Debug, Deserialize)] @@ -53,19 +53,19 @@ struct ConfigToml { pub struct CLIArguments { /// Path to the config file #[arg(default_value = "config.toml")] - config: PathBuf, + pub config: PathBuf, /// Maximum amount of workers to use. /// If not set, the max is calculated depending on system resources. /// A value of 0 will cause the server to be singlethreaded, potentially reducing the performance and responsiveness by a lot #[arg(long)] - max_workers: Option, + pub max_workers: Option, /// Minimum amount of workers to keep active at all times /// Can potentially increase reaction speed at the cost of resource usage #[arg(long)] - min_workers: Option, + pub min_workers: Option, #[arg(long)] - db_path: Option, + pub db_path: Option, } pub fn read_from_env() -> Result {