mirror of
https://github.com/scsibug/nostr-rs-relay.git
synced 2024-11-24 17:49:07 -05:00
feat: roll over logs daily
This commit is contained in:
parent
f4beb884b3
commit
9237eed735
|
@ -42,7 +42,7 @@ fn main() {
|
||||||
Some(p) => p.as_str(),
|
Some(p) => p.as_str(),
|
||||||
None => "relay",
|
None => "relay",
|
||||||
};
|
};
|
||||||
let file_appender = tracing_appender::rolling::hourly(path, prefix);
|
let file_appender = tracing_appender::rolling::daily(path, prefix);
|
||||||
let (non_blocking, guard) = tracing_appender::non_blocking(file_appender);
|
let (non_blocking, guard) = tracing_appender::non_blocking(file_appender);
|
||||||
let filter = EnvFilter::from_default_env();
|
let filter = EnvFilter::from_default_env();
|
||||||
// assign to a variable that is not dropped till the program ends
|
// assign to a variable that is not dropped till the program ends
|
||||||
|
|
Loading…
Reference in New Issue
Block a user