Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
Yong Sheng Tan committed Feb 10, 2024
1 parent 29e76dd commit c36a2b6
Showing 1 changed file with 14 additions and 3 deletions.
17 changes: 14 additions & 3 deletions DockerFile
Original file line number Diff line number Diff line change
@@ -1,9 +1,20 @@
FROM python:3.9

WORKDIR /
WORKDIR /code

COPY requirements.txt ./
COPY requirements.txt /code/requirements.txt

RUN pip install --no-cache-dir --upgrade -r ./requirements.txt
RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt

RUN useradd -m -u 1000 user

USER user

ENV HOME=/home/user \
PATH=/home/user/.local/bin:$PATH

WORKDIR $HOME/app

COPY --chown=user . $HOME/app

CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "7860"]

0 comments on commit c36a2b6

Please sign in to comment.