code: def get_public_network_ip(ips, public_subnet):
      
      for ip in ips:
          if net.ip_in_subnet(ip, public_subnet):
              return ip
      msg = "IPs (%s) are not valid for any of subnet specified %s" % (str(ips), str(public_subnet))
      raise RuntimeError(msg)
docs: Given a public subnet, chose the one IP from the remote host that exists
      within the subnet range.