Skip to content
This repository has been archived by the owner on Jun 17, 2024. It is now read-only.

Commit

Permalink
make starting port configurable
Browse files Browse the repository at this point in the history
  • Loading branch information
radufalcusan committed Apr 8, 2024
1 parent 000eaf5 commit fc1a09c
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
FROM python:3.8-slim-buster

ENV PORT=8081

COPY requirements.txt requirements.txt
RUN pip3 install -r requirements.txt

Expand All @@ -11,4 +13,4 @@ RUN chmod +x ./entrypoint.sh

ENTRYPOINT ["/entrypoint.sh"]

CMD ["uvicorn", "src.app:app", "--reload", "--host", "0.0.0.0", "--port", "8001"]
CMD ["sh", "-c", "uvicorn src.app:app --reload --host 0.0.0.0 --port $PORT"]

0 comments on commit fc1a09c

Please sign in to comment.