title: How to create and configure a base docker images from iso
body: <p>I miserably failed to find any sound instructions on how to do that. All I've tried so far was of no effect. Here's the best I could do:</p>
  
  <pre><code>$ sudo mount -o loop ubuntu-18.04.1-live-server-amd64.iso rootfs
  $ cd rootsfs
  $ sudo tar -c . | sudo docker import - ubuntuserver
  </code></pre>
  
  <p>It does create an image but here is the thing, the <code>sudo docker image inspect ubuntuserver</code> returns a somewhat empty config. I would really like to change a whole lot of things there, but I could not. I've managed to change some fields with the help of <code>docker import --change</code> but not all of them. I've also tried opening the json in the text editor and editing it but after I save the file , the docker image becomes invisible and is no longer displayed by the <code>docker images</code> command.</p>
  
  <p>If I try to create a container from the image like so:</p>
  
  <pre><code>sudo docker run -it ubuntuserver /bin/bash
  </code></pre>
  
  <p>I get the following error:</p>
  
  <pre><code>docker: Error response from daemon: OCI runtime create failed: container_linux.go:348: starting container process caused "exec: \"/bin/bash\": stat /bin/bash: no such file or directory": unknown.
  </code></pre>
  
  <p>But seems like it's obviously because the image is not configured properly.</p>