Clean up --gossip-port argument (#7067)

--gossip-port now specifies exactly that, the gossip port to use.  The
new --gossip-host argument can be used to specify the DNS name/IP
address for gossip if --entrypoint is not supplied (when --entrypoint is
supplied, the gossip address is automatically set to the node's ip
address as observed by the entrypoint)
This commit is contained in:
Michael Vines
2019-11-20 15:21:34 -07:00
committed by GitHub
parent c39633f968
commit b0271394cd
5 changed files with 92 additions and 50 deletions

View File

@ -48,3 +48,9 @@ pub fn is_release_channel(channel: &str) -> Result<(), String> {
_ => Err(format!("Invalid release channel {}", channel)),
}
}
pub fn is_port(port: String) -> Result<(), String> {
port.parse::<u16>()
.map(|_| ())
.map_err(|e| format!("{:?}", e))
}