feat(rp): Enable logging

This commit is contained in:
Karolin Varner
2025-08-02 16:52:06 +02:00
parent edcbf290fc
commit c689f8e78a
3 changed files with 8 additions and 0 deletions

2
Cargo.lock generated
View File

@@ -2228,10 +2228,12 @@ dependencies = [
"anyhow",
"base64ct",
"ctrlc-async",
"env_logger",
"futures",
"futures-util",
"genetlink",
"libc",
"log",
"netlink-packet-core",
"netlink-packet-generic",
"netlink-packet-wireguard",

View File

@@ -18,6 +18,8 @@ toml = { workspace = true }
x25519-dalek = { workspace = true, features = ["static_secrets"] }
zeroize = { workspace = true }
libc = { workspace = true }
log = { workspace = true }
env_logger = { workspace = true }
rosenpass = { workspace = true }
rosenpass-ciphers = { workspace = true }

View File

@@ -24,6 +24,10 @@ async fn main() -> anyhow::Result<()> {
}
};
// init logging
// TODO: Taken from rosenpass; we should deduplicate the code.
env_logger::Builder::from_default_env().init(); // sets log level filter from environment (or defaults)
let command = cli.command.unwrap();
match command {