add EXTRA_RUST_LOG helper
This commit is contained in:
parent
f68964f63d
commit
8cb57e2f88
@ -134,7 +134,7 @@ fn main() -> anyhow::Result<()> {
|
|||||||
|
|
||||||
// if RUST_LOG isn't set, configure a default
|
// if RUST_LOG isn't set, configure a default
|
||||||
#[cfg(not(feature = "tokio_console"))]
|
#[cfg(not(feature = "tokio_console"))]
|
||||||
let rust_log = match std::env::var("RUST_LOG") {
|
let mut rust_log = match std::env::var("RUST_LOG") {
|
||||||
Ok(x) => x,
|
Ok(x) => x,
|
||||||
Err(_) => match std::env::var("WEB3_PROXY_TRACE").map(|x| x == "true") {
|
Err(_) => match std::env::var("WEB3_PROXY_TRACE").map(|x| x == "true") {
|
||||||
Ok(true) => {
|
Ok(true) => {
|
||||||
@ -170,6 +170,11 @@ fn main() -> anyhow::Result<()> {
|
|||||||
.join(","),
|
.join(","),
|
||||||
};
|
};
|
||||||
|
|
||||||
|
if let Ok(extra_rust_log) = std::env::var("EXTRA_RUST_LOG") {
|
||||||
|
rust_log.push(',');
|
||||||
|
rust_log.push_str(&extra_rust_log);
|
||||||
|
}
|
||||||
|
|
||||||
let mut cli_config: Web3ProxyCli = argh::from_env();
|
let mut cli_config: Web3ProxyCli = argh::from_env();
|
||||||
|
|
||||||
if cli_config.config.is_none() && cli_config.db_url.is_none() && cli_config.sentry_url.is_none()
|
if cli_config.config.is_none() && cli_config.db_url.is_none() && cli_config.sentry_url.is_none()
|
||||||
|
Loading…
Reference in New Issue
Block a user