nakas's picture
Update Dockerfile
7ae98fd verified
raw
history blame
580 Bytes
FROM python:3.9-slim
WORKDIR /app
# Install system dependencies
RUN apt-get update && apt-get install -y \
build-essential \
git \
&& rm -rf /var/lib/apt/lists/*
# Copy requirements file
COPY requirements.txt .
# Install Python dependencies
RUN pip install --no-cache-dir -r requirements.txt
# Copy application files
COPY app.py .
COPY utils.py .
# Environment variables will be set in the Hugging Face Space UI
# OPENAI_API_KEY should be added as a secret
# Expose port for the application
EXPOSE 7860
# Command to run the application
CMD ["python", "app.py"]