title: host command run inside docker container doesn't resolve container hostname, but ping does
body: <p>I'm running the below commands 
  inside docker container shell <code>[root@quickstart /]</code></p>
  
  <ul>
  <li><p><code>hostname</code> returns <code>quickstart</code></p></li>
  <li><p><code>hostname -i</code> return <code>172.17.0.3</code></p></li>
  </ul>
  
  <p>However, <code>host quickstart</code> returns
  <code>Host quickstart not found: 3(NXDOMAIN)</code> </p>
  
  <p>and  <code>[root@quickstart /]# host quickstart.cloudera</code> returns</p>
  
  <p><code>Host quickstart.cloudera not found: 3(NXDOMAIN)</code></p>
  
  <ul>
  <li><code>ping -q -c 1 quickstart</code></li>
  </ul>
  
  <p>returns </p>
  
  <pre><code>PING quickstart.cloudera (172.17.0.3) 56(84) bytes of data.
  
  --- quickstart.cloudera ping statistics ---
  1 packets transmitted, 1 received, 0% packet loss, time 0ms
  rtt min/avg/max/mdev = 0.053/0.053/0.053/0.000 ms
  </code></pre>
  
  <p>The container was started using <code>docker run --name my_cloudera    --hostname=quickstart.cloudera    --privileged=true    -td        -p 8888:8888    -p 7180:7180    -p 6680:80    -v ~/cloudera_data/lib:/var/lib    my_cloudera /usr/bin/docker-quickstart</code></p>
  
  <p>container <code>/etc/hosts</code> shows:</p>
  
  <p><code>[root@quickstart /]# cat /etc/hosts
  127.0.0.1   localhost
  ::1 localhost ip6-localhost ip6-loopback
  fe00::0 ip6-localnet
  ff00::0 ip6-mcastprefix
  ff02::1 ip6-allnodes
  ff02::2 ip6-allrouters
  172.17.0.3  quickstart.cloudera quickstart</code></p>
  
  <p>docker daemon is running on MacOS</p>
  
  <p>How to cause <code>host</code> to resolve <code>quickstart.cloudera</code> container hostname?</p>