From 813f9c57d227a686c6fb08137a2b6b26e9986ef4 Mon Sep 17 00:00:00 2001 From: tv Date: Mon, 26 Oct 2026 23:21:01 +0100 Subject: show interpolated values in GET /admin/config --- src/main.rs | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) (limited to 'src/main.rs') diff --git a/src/main.rs b/src/main.rs index 0cda7ca..76086ca 100644 --- a/src/main.rs +++ b/src/main.rs @@ -43,7 +43,10 @@ async fn main() -> Result<()> { let config = config::load()?; if config.print_only { - println!("{}", serde_json::to_string_pretty(&config.report())?); + println!( + "{}", + serde_json::to_string_pretty(&config.report(config::Values::Interpolated))? + ); return Ok(()); } let args = &config.settings; @@ -84,10 +87,10 @@ async fn main() -> Result<()> { bind_addr = args.bind_addr.to_string(), "Starting replication service" ); - debug!( - url = mycelium_rest_url.to_string(), - "Using Mycelium REST API" - ); + // Without a password it may carry (the option is secret). + let mut shown_url = mycelium_rest_url.clone(); + let _ = shown_url.set_password(None); + debug!(url = shown_url.to_string(), "Using Mycelium REST API"); let force = force::Force::parse(args.force.iter().map(String::as_str), config::FORCE) .map_err(anyhow::Error::msg)?; @@ -181,7 +184,7 @@ async fn main() -> Result<()> { files, state_file, document_file, - config_report: config.report(), + config_reports: config.reports(), clock: Default::default(), }); let state = node.state.clone(); -- cgit v1.3.1