Porthole resolves open network ports so you don’t have to.
println!("next available port is {}", porthole::open().unwrap())