title: How to update /etc/hosts file in Docker image during "docker build"
body: <p>I want to update my <code>/etc/hosts</code> file during "docker build".</p>
  
  <p>I added below line in Dockerfile but it's neither updating <code>/etc/hosts</code> file nor giving any error.</p>
  
  <pre><code>RUN echo "192.168.33.11    mynginx" &gt;&gt; /etc/hosts
  </code></pre>
  
  <p>I need to update <code>/etc/hosts</code>. Can anyone suggest on this?</p>