-
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
8797890
commit 528fcd8
Showing
1 changed file
with
13 additions
and
4 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,11 +1,20 @@ | ||
FROM python:3.10-slim | ||
# Use the official Python image | ||
FROM python:3.11 | ||
|
||
# Create and change to the app directory | ||
WORKDIR /app | ||
COPY api/requirements.txt ./api/ | ||
|
||
COPY ./api . | ||
|
||
# Install dependencies for the api folder | ||
WORKDIR /app/api | ||
RUN pip install --no-cache-dir -r requirements.txt | ||
|
||
# Copy the local code to the container image | ||
WORKDIR /app | ||
COPY . . | ||
|
||
# Expose port 3000 | ||
EXPOSE 3000 | ||
|
||
CMD ["python", "main.py"] | ||
# Run the web service on container startup | ||
CMD ["gunicorn", "-c", "api/gunicorn_config.py", "api.main:app"] |