cleanup path handling for easier dockerization

This commit is contained in:
2024-06-30 18:42:59 +02:00
parent bec1827891
commit 49ce8527a3
12 changed files with 126 additions and 118 deletions

View File

@@ -6,6 +6,11 @@ COPY Pipfile Pipfile.lock .
RUN pip install pipenv
RUN pipenv install --deploy --system
COPY . /src
COPY src src
CMD ["pipenv", "run", "python", "/app/src/main.py"]
EXPOSE 8000
# Set environment variables used by the deployment. These can be overridden by the user using this image.
ENV NUM_WORKERS=1
CMD ["pipenv", "run", "fastapi", "run", "src/main.py", '--port 8000', '--workers $NUM_WORKERS']