Allow to control tracing from the environment
This commit is contained in:
parent
e4765a20ef
commit
da7d012393
1 changed files with 2 additions and 0 deletions
|
|
@ -8,6 +8,7 @@ use migration::{Migrator, MigratorTrait};
|
|||
use sea_orm::{ConnectOptions, Database, DatabaseConnection};
|
||||
use serde::{Deserialize, Deserializer, Serialize, Serializer};
|
||||
use tower_http::services::ServeDir;
|
||||
use tracing_subscriber::EnvFilter;
|
||||
|
||||
pub(crate) mod entity;
|
||||
mod routes;
|
||||
|
|
@ -101,6 +102,7 @@ async fn main() -> anyhow::Result<()> {
|
|||
tracing_subscriber::fmt()
|
||||
.with_max_level(tracing::Level::DEBUG)
|
||||
.with_test_writer()
|
||||
.with_env_filter(EnvFilter::from_default_env())
|
||||
.init();
|
||||
|
||||
let config = Settings::new()?;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue