You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

Dockerfile 475B

12345678910111213141516
  1. # init a base image (Alpine is small Linux distro)
  2. FROM python:3.10-alpine
  3. # update pip to minimize dependency errors
  4. RUN pip install --upgrade pip
  5. # define the present working directory
  6. WORKDIR /docker-flask-test
  7. # copy the contents into the working dir
  8. ADD . /docker-flask-test
  9. # run pip to install the dependencies of the flask app
  10. RUN pip install -r requirements.txt
  11. WORKDIR flask_server
  12. EXPOSE 5000
  13. # define the command to start the container
  14. CMD ["python","app.py"]