title: Connect mongodb docker container to localhost
body: <p>I am trying to bind port of docker container that is mongodb in docker to localhost. I tried doing:
  <code>sudo docker run -p 127.0.0.1:27018:27017 mongo:3.2</code></p>
  
  <p>I could able to connect to it but the databases added in docker containers are not exposed to local.</p>
  
  <p>I even tried of binding <code>0.0.0.0.</code> and <code>192.168.x.x</code> that is my ip address also instead of <code>127.0.0.1</code>. In all cases i am not getting the databases in mongo docker container</p>