Spaces:
Sleeping
Sleeping
# Use the official Python base image | |
FROM python:3.9 | |
# Set the working directory in the container | |
WORKDIR /app | |
# Copy the requirements.txt file into the container | |
COPY requirements.txt . | |
# Install the Python dependencies | |
RUN pip install --no-cache-dir -r requirements.txt | |
# Install en_core_web_sm | |
RUN pip install https://github.com/explosion/spacy-models/releases/download/en_core_web_sm-3.5.0/en_core_web_sm-3.5.0.tar.gz --user | |
# Copy the rest of the application code into the container | |
COPY . . | |
# Expose the port that the app will run on | |
EXPOSE 7860 | |
# Start the FastAPI app using Uvicorn | |
CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "8000"] | |