diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 0000000..7e550e7 --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,7 @@ +# CONTRIBUTING + +## How to run the Dockerfile locally + +``` +docker run -dp 5000:5000 -w /app -v "$(pwd):/app" IMAGE_NAME sh -c "flask run" +``` diff --git a/Dockerfile b/Dockerfile index f6b55d6..12f16d8 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,7 +1,6 @@ FROM python:3.10 -EXPOSE 5000 WORKDIR /app COPY requirements.txt . -RUN pip install -r requirements.txt +RUN pip install --no-cache-dir --upgrade -r requirements.txt COPY . . -CMD ["flask", "run", "--host", "0.0.0.0"] \ No newline at end of file +CMD ["gunicorn", "--bind", "0.0.0.0:80", "app:create_app()"] \ No newline at end of file diff --git a/requirements.txt b/requirements.txt index c288b79..b1c61dd 100644 --- a/requirements.txt +++ b/requirements.txt @@ -5,4 +5,5 @@ sqlalchemy flask-sqlalchemy flask-jwt-extended passlib -flask-migrate \ No newline at end of file +flask-migrate +gunicorn \ No newline at end of file