Spaces:
Running
Running
File size: 540 Bytes
472efd1 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 | FROM python:3.10-slim
WORKDIR /app
# Install system deps
RUN apt-get update && \
apt-get install -y nginx supervisor && \
rm -rf /var/lib/apt/lists/*
# Install Python deps
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
# Copy app code
COPY . .
# Copy configs
COPY nginx.conf /etc/nginx/nginx.conf
COPY supervisor.conf /etc/supervisor/conf.d/supervisor.conf
# Expose HF Space port
EXPOSE 7860
# Start everything
CMD ["sh", "-c", "nginx && supervisord -n -c /etc/supervisor/conf.d/supervisor.conf"]
|