feat: add rpc cli flags (#29)
This commit is contained in:
parent
56385f15ed
commit
8e080faf4a
|
@ -37,6 +37,14 @@ fn get_config() -> Result<Config> {
|
||||||
config.general.rpc_port = Some(port);
|
config.general.rpc_port = Some(port);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if let Some(execution_rpc) = cli.execution_rpc {
|
||||||
|
config.general.execution_rpc = execution_rpc;
|
||||||
|
}
|
||||||
|
|
||||||
|
if let Some(consensus_rpc) = cli.consensus_rpc {
|
||||||
|
config.general.consensus_rpc = consensus_rpc;
|
||||||
|
}
|
||||||
|
|
||||||
Ok(config)
|
Ok(config)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -46,6 +54,10 @@ struct Cli {
|
||||||
network: String,
|
network: String,
|
||||||
#[clap(short, long)]
|
#[clap(short, long)]
|
||||||
port: Option<u16>,
|
port: Option<u16>,
|
||||||
#[clap(short, long)]
|
#[clap(short = 'w', long)]
|
||||||
checkpoint: Option<String>,
|
checkpoint: Option<String>,
|
||||||
|
#[clap(short, long)]
|
||||||
|
execution_rpc: Option<String>,
|
||||||
|
#[clap(short, long)]
|
||||||
|
consensus_rpc: Option<String>,
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue