title: Empty response returned docker flask application
body: <p>So I have a simple flask application that uses Flask-Script and runs:</p>
  
  <pre><code>if __name__ == "__main__":
      manager.run()
  </code></pre>
  
  <p>My dockerfile:</p>
  
  <pre><code>CMD [ "python", "manage.py", "runserver", "-h", "0.0.0.0"]
  </code></pre>
  
  <p>I added the -h 0.0.0.0 so it could bind to docker localhost</p>
  
  <p>I then run the docker container with to expost port 5000:</p>
  
  <pre><code>docker run -p 5000:5000 flask-app
  </code></pre>
  
  <p>This then runs and prints the following which tells me my app is running:</p>
  
  <pre><code> * Running on http://127.0.0.1:5000/ (Press CTRL+C to quit)
   * Restarting with stat
  </code></pre>
  
  <p>I try to curl on my host but get an empty response error:</p>
  
  <pre><code>* Empty reply from server 
  * Connection #0 to host localhost left intact
  </code></pre>
  
  <p>I then get a shell into my container and see that my app is listening on the wrong address (should be 0.0.0.0)</p>
  
  <pre><code>root@91d7d0e2331c:/app# netstat -tln
  Active Internet connections (only servers)
  Proto Recv-Q Send-Q Local Address           Foreign Address         State      
  tcp        0      0 127.0.0.1:5000          0.0.0.0:*               LISTEN 
  </code></pre>
  
  <p>Not sure what I am doing wrong here...</p>