FROM python:3.11-slim | |
#add new comment | |
# Set environment variables | |
ENV DEBIAN_FRONTEND=noninteractive | |
ENV TZ=UTC | |
# Install system dependencies | |
RUN apt-get update && apt-get install -y \ | |
build-essential \ | |
libsqlite3-dev \ | |
&& rm -rf /var/lib/apt/lists/* | |
# Set working directory | |
WORKDIR /app | |
# Install Python dependencies | |
RUN pip install --no-cache-dir --upgrade pip setuptools && \ | |
pip install --no-cache-dir \ | |
fastapi==0.113.0 \ | |
uvicorn==0.30.6 \ | |
joblib==1.4.2 \ | |
chromadb==0.5.5 \ | |
openai==0.28.0 \ | |
numpy==1.26.4 | |
# Copy your application files | |
COPY . . | |
# Expose the port | |
EXPOSE 7860 | |
# Command to run your application | |
CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "7860"] | |