Skip to content

Commit a0bf67c

Browse files
authored
fix: use provided log_dir_path in tracing init (#239)
1 parent 7fa6838 commit a0bf67c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

crates/common/src/utils.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ use tracing_appender::{non_blocking::WorkerGuard, rolling::Rotation};
1818
use tracing_subscriber::{fmt::Layer, prelude::*, EnvFilter};
1919

2020
use crate::{
21-
config::{load_optional_env_var, LogsSettings, LOGS_DIR_DEFAULT, PBS_MODULE_NAME},
21+
config::{load_optional_env_var, LogsSettings, PBS_MODULE_NAME},
2222
pbs::HEADER_VERSION_VALUE,
2323
types::Chain,
2424
};
@@ -183,7 +183,7 @@ pub fn initialize_tracing_log(module_id: &str) -> eyre::Result<WorkerGuard> {
183183
}
184184
let file_appender = builder
185185
.rotation(Rotation::DAILY)
186-
.build(LOGS_DIR_DEFAULT)
186+
.build(settings.log_dir_path)
187187
.expect("failed building rolling file appender");
188188

189189
let (writer, guard) = tracing_appender::non_blocking(file_appender);

0 commit comments

Comments
 (0)