title: python: Cant expose flask app in docker container
body: <p>I have a Flask app that works localy but i cant get it to work running in a docker container.</p>
  <p>Structure of the project:</p>
  <p><a href="https://i.stack.imgur.com/hTnmA.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/hTnmA.png" alt="Tree structure of the project" /></a></p>
  <p>Contents of the Dockerfile:</p>
  <pre><code>FROM python:3.9
  
  ENV PYTHONDONTWRITEBYTECODE 1
  ENV PYTHONUNBUFFERED 1
  
  WORKDIR /code
  
  COPY Pipfile Pipfile.lock /code/
  RUN pip install --upgrade pip
  RUN pip install pipenv &amp;&amp; pipenv install --skip-lock --system
  
  COPY . /code/
  
  CMD [&quot;python3&quot;, &quot;./run.py&quot;]
  </code></pre>
  <p>this are the comands i use to build and run the image</p>
  <pre><code>docker build --tag time-managment .
  docker run -p 5000:5000 time-managment
  </code></pre>
  <p>And the container semms to run fine.</p>
  <p>Docker ps:
  <a href="https://i.stack.imgur.com/GWLSc.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/GWLSc.png" alt="docker ps" /></a></p>
  <p>FLask message:
  <a href="https://i.stack.imgur.com/PIKSN.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/PIKSN.png" alt="FLask running" /></a></p>
  <p>But i cant acces it with my browser i just get a &quot;This page does not work&quot; message, no uptades on the logs or anything.</p>
  <p>What am i doing Wrong?</p>