title: Docker - connect to host Postgres raises: Error starting userland proxy: listen tcp4 127.0.0.1:5432: bind: address already in use
body: <p>I'm fairly new to <code>Docker</code> and I'm trying to create a Django development container. I have <code>Postgres</code> database running on my PC on port <code>5432</code>.</p>
  <p>I run this command:</p>
  <pre><code>docker run --env-file .env.dev -p 127.0.0.1:5432:5432 test sh -c &quot;python manage.py makemigrations &amp;&amp; python manage.py migrate&quot;
  </code></pre>
  <p>Which returns:</p>
  <pre><code>Error starting userland proxy: listen tcp4 127.0.0.1:5432: bind: address already in use.
  </code></pre>
  <p>I understand that host port <code>5432</code> is already in use by <code>Postgres</code> but AFAIK I should map dockers <code>5432</code> to <code>5432</code> to be able to connect to the database, shouldn't I?</p>