-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
1154335
commit e3c54cc
Showing
1 changed file
with
3 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,15 @@ | ||
FROM python:3.10-slim AS builder | ||
FROM python:3.12-slim AS builder | ||
RUN pip install poetry | ||
WORKDIR /app | ||
COPY pyproject.toml poetry.lock ./ | ||
RUN poetry export -f requirements.txt --output requirements.txt --without-hashes | ||
|
||
FROM python:3.10-slim | ||
FROM python:3.12-slim | ||
WORKDIR /app | ||
COPY --from=builder /app/requirements.txt . | ||
RUN pip install --no-cache-dir -r requirements.txt | ||
COPY . . | ||
EXPOSE 8000 | ||
ENV PYTHONUNBUFFERED=1 | ||
|
||
CMD ["fastapi", "app.main:app", "--host", "0.0.0.0", "--port", "8000"] | ||
CMD ["fastapi", "app/main.py", "--host", "0.0.0.0", "--port", "8000"] |