title: Purpose of FROM command - Docker file
body: <p><strong>Main purpose</strong> of Docker container is to avoid carrying guest OS in every container, as shown below.</p>
  
  <p><a href="https://i.stack.imgur.com/Mg679.png" rel="noreferrer"><img src="https://i.stack.imgur.com/Mg679.png" alt="enter image description here"></a>
  As mentioned <a href="https://docs.docker.com/engine/reference/builder/#from" rel="noreferrer">here</a>,  The <code>FROM</code> instruction initializes a new build stage and sets the Base Image for subsequent instructions. As such, <strong>a valid Dockerfile must start</strong> with a <code>FROM</code> instruction.</p>
  
  <p>My understanding is, <code>FROM &lt;image&gt;</code> allow a container to run on its own OS.</p>
  
  <hr>
  
  <p>Why a valid Docker file must have <code>FROM</code> instruction?</p>