File size: 478 Bytes
61bc1ff 285a9e6 61bc1ff 285a9e6 61bc1ff 285a9e6 61bc1ff 285a9e6 3bd6f72 285a9e6 3bd6f72 61bc1ff 285a9e6 |
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
# Create a user to avoid running as root
RUN useradd -m -u 1000 user
USER user
# Add Python bin path to environment
ENV PATH="/home/user/.local/bin:$PATH"
# Set working directory
WORKDIR /app
# Copy files
COPY --chown=user . /app
# Install dependencies
RUN pip install --no-cache-dir -r requirements.txt
# Run Streamlit app on Hugging Face-required port (7860)
CMD ["streamlit", "run", "streamlit_app.py", "--server.port=7860", "--server.address=0.0.0.0"]
|