title: Simple flask service do not respond outside a docker container
body: <p>Hi and thanks in advance, I'm new to docker, I'm stuck on a simple docker example exposing a flask service outside a container.</p>
  
  <p>I have a folder called <code>rest_example</code> and inside a dockerfile and a .py file.
  This is my dockerfile:</p>
  
  <pre><code>FROM ubuntu:16.04
  LABEL maintainer="Lorem Ipsum"
  RUN apt-get update  &amp;&amp;  \
      apt-get install -y python  &amp;&amp; \
      apt-get install -y python-pip  &amp;&amp; \
      pip install Flask  &amp;&amp; \
      apt-get install -y curl  &amp;&amp; \
      mkdir files
  COPY flask_example.py /files
  ENV FLASK_APP /files/flask_example.py
  EXPOSE 5000
  CMD flask run
  </code></pre>
  
  <p>This is flask_example.py:</p>
  
  <pre><code>from flask import Flask
  
  app = Flask(__name__)
  
  @app.route("/hello")
  def hello():
      return "Hello World!"
  </code></pre>
  
  <p>I'm creating image like this: 
  docker run rest_example -t -p 5000:5000 --name=rest_example --rm</p>
  
  <p>When I hit <code>curl localhost:5000/hello</code> inside the container this is the response:
  <code>Hello World!</code>, is means that flask is up inside the container BUT, in my local browser there are not response for that url.</p>