Spaces:
Sleeping
Sleeping
File size: 303 Bytes
d353ab5 f142e73 75c6766 f142e73 75c6766 fb283a1 f142e73 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 | FROM python:3.9
WORKDIR /app
# Create a non-root user with UID 1000
RUN useradd -m -u 1000 user
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
COPY . .
# Switch to the non-root user
USER user
# Expose port 7860
EXPOSE 7860
# Run the server
CMD ["python", "server.py"]
|