diff --git a/node/tools/src/bin/deployer.rs b/node/tools/src/bin/deployer.rs index a3ea667f..f63cac84 100644 --- a/node/tools/src/bin/deployer.rs +++ b/node/tools/src/bin/deployer.rs @@ -1,7 +1,9 @@ //! Deployer for the kubernetes cluster. use clap::Parser; -use std::collections::HashMap; -use std::net::{Ipv4Addr, SocketAddr}; +use std::{ + collections::HashMap, + net::{Ipv4Addr, SocketAddr}, +}; use zksync_consensus_roles::{node::SecretKey, validator}; use zksync_consensus_tools::{k8s, k8s::ConsensusNode, AppConfig, NODES_PORT}; diff --git a/node/tools/src/bin/localnet_config.rs b/node/tools/src/bin/localnet_config.rs index 844f1a84..6d548648 100644 --- a/node/tools/src/bin/localnet_config.rs +++ b/node/tools/src/bin/localnet_config.rs @@ -2,8 +2,8 @@ use anyhow::Context as _; use clap::Parser; use rand::Rng; -use std::collections::{HashMap, HashSet}; use std::{ + collections::{HashMap, HashSet}, fs, net::{Ipv4Addr, SocketAddr}, path::PathBuf, diff --git a/node/tools/src/main.rs b/node/tools/src/main.rs index 8677573d..88659400 100644 --- a/node/tools/src/main.rs +++ b/node/tools/src/main.rs @@ -88,6 +88,7 @@ impl Cli { } } +/// Overrides `cfg.public_addr`, based on the `PUBLIC_ADDR` env variable. fn check_public_addr(cfg: &mut AppConfig) -> anyhow::Result<()> { if let Ok(public_addr) = std::env::var("PUBLIC_ADDR") { cfg.public_addr = std::net::SocketAddr::new(public_addr.parse()?, NODES_PORT).into();