Startup script for a docker container
<p>I have a docker container already running. I have made some configuration changes, let's say have added some host info in /etc/hosts inside the container. How do I keep the changes saved, so that next time when I open an interactive shell to the container I don't have to do the same stuff again ? For now I have created a mini script as addhosts.sh as below inside the container and have to run it every time.</p>

<pre><code>echo "1.2.3.4 server1.example.com gluster1" &gt;&gt; /etc/hosts
echo "5.6.7.8 server2.example.com gluster2" &gt;&gt; /etc/hosts
</code></pre>

<p>This is one of the cases. Similarly, I need all my configuration to be intact. Please don't suggest for dockerfile as I'm not creating an image rather I'm just getting into the container. </p>