Project

General

Profile

Bug #12838 ยป client.rb

 
1
#!/usr/bin/env ruby
2

    
3
require 'resolv'
4

    
5
Resolv::DefaultResolver.replace_resolvers(
6
  [Resolv::Hosts.new, Resolv::DNS.new(nameserver: '127.0.0.1', search: ['bad1.com', 'bad2.com', 'good.com'], ndots: 5)]
7
)
8

    
9
puts Resolv.getaddress("example")