Spaces:
Runtime error
Runtime error
File size: 477 Bytes
0395962 e192eff a9b9639 0395962 e192eff a9b9639 0395962 e192eff 0395962 e192eff a9b9639 0395962 e192eff a9b9639 0395962 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 | FROM python:3.10-slim
WORKDIR /app
# Copy files
COPY ./src /app/src
COPY requirements.txt .
# Create a safe cache directory
RUN mkdir -p /app/cache
# Install dependencies
RUN pip install --no-cache-dir -r requirements.txt
# Set environment variables for safe caching
ENV HF_HOME=/app/cache
ENV TRANSFORMERS_CACHE=/app/cache
ENV STREAMLIT_SERVER_HEADLESS=true
# Run the app
CMD ["streamlit", "run", "src/streamlit_app.py", "--server.port=7860", "--server.address=0.0.0.0"] |