Move logging config to main configuration file.

- Move the content of what was stored in log4rs.yml into the main config
  file, so that there is just one file to parse to get the complete
  configuration.
- Create the global switch `--home` to pass/overload the value for
  SEQUOIA_HOME in the configuration file.
This commit is contained in:
Malte Meiboom
2026-05-18 11:11:22 +02:00
parent 6611a43a24
commit 14dca91d92
5 changed files with 81 additions and 23 deletions
+21
View File
@@ -1,3 +1,24 @@
//! Defaults
pub const CONFIG_FILE_LOCATION: &'static str = "/etc/husk/config.toml";
/// Default logging configuration.
pub const CONSOLE_LOGGING: &'static str = "
[appenders.console]
kind = \"console\"
[appenders.console.encoder]
pattern = \"{d(%Y-%m-%d %H:%M:%S)(local)} {h({l})} [{t}] {m}{n}\"
[[appenders.console.filters]]
kind = \"threshold\"
level = \"debug\"
[root]
level = \"info\"
appenders = [\"console\"]
[loggers.\"husk\"]
level = \"debug\"
";