Rajan Sharma
Update Dockerfile to run app.py
abae5bd verified
raw
history blame contribute delete
430 Bytes
# Use Python 3.11 base image
FROM python:3.11
# Create a non-root user (recommended by HF)
RUN useradd -m -u 1000 user
WORKDIR /app
# Copy and install dependencies
COPY requirements.txt /app/requirements.txt
RUN pip install --no-cache-dir --upgrade -r requirements.txt
# Copy the rest of the application code
COPY . /app
# Set environment variables (optional)
ENV PYTHONUNBUFFERED=1
# Default command
CMD ["python", "app.py"]