backend / Dockerfile
SolarumAsteridion's picture
Initial commit with preprocessing and base64 forwarding
05991fd
raw
history blame contribute delete
517 Bytes
# Use Python 3.9 for compatibility with standard HF Docker Spaces
FROM python:3.9
# Create a non-root user to avoid permission issues
RUN useradd -m -u 1000 user
USER user
ENV PATH="/home/user/.local/bin:$PATH"
WORKDIR /app
# Copy and install requirements
COPY --chown=user ./requirements.txt requirements.txt
RUN pip install --no-cache-dir --upgrade -r requirements.txt
# Copy the application code
COPY --chown=user . /app
# Run the application
CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860"]