def host_routable_ip(target_ip = docker_routable_ip)
      best_match  = ''
      best_prefix = 0

      target_cps = target_ip.codepoints

      @my_ips.each do |my_ip|
        ip_cps = my_ip.codepoints
        prefix = 0
        ip_cps.each_with_index do |cp, i|
          break unless target_cps[i] == cp
          prefix = i
        end

        if prefix > best_prefix
          best_match = my_ip
          best_prefix = prefix
        end
      end

      best_match
    end
def host_routable_ip(target_ip = docker_routable_ip)
      best_match  = ''
      best_prefix = 0

      target_cps = target_ip.codepoints

      @my_ips.each do |my_ip|
        ip_cps = my_ip.codepoints
        prefix = 0
        ip_cps.each_with_index do |cp, i|
          break unless target_cps[i] == cp
          prefix = i
        end

        if prefix > best_prefix
          best_match = my_ip
          best_prefix = prefix
        end
      end

      best_match
    end
Create a new instance of this class.
 @param [String] docker_host a URI pointing to the docker host
 @param [Array] list of String dotted-quad IPv4 addresses of local host
 Examine local host's network interfaces; figure out which one is most
 likely to share a route with the given IP address. If no IP address
 is specified, figure out which IP the Docker daemon is reachable on
 and use that as the target IP.

 @param [String] target_ip IPv4 address of target

 @return [String] IPv4 address of host machine that _may_ be reachable from
   Docker machine