Spaces:
Runtime error
Runtime error
File size: 901 Bytes
736730d 11b6c0d f2555bb 736730d 11b6c0d f2555bb 11b6c0d 736730d |
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 27 28 29 30 31 32 33 34 35 36 37 |
# Use an official Python runtime as the base image
FROM python:3.11-slim
# Set working directory in the container
WORKDIR /app
# Copy project files
COPY app.py utils.py agents.py tasks.py requirements.txt ./
# Install system dependencies
RUN apt-get update && apt-get install -y \
gcc \
libffi-dev \
&& rm -rf /var/lib/apt/lists/*
# Install Python dependencies
RUN pip install --no-cache-dir -r requirements.txt
# Expose port 7860 for Gradio
EXPOSE 7860
# Set environment variables
ENV CREWAI_TELEMETRY_ENABLED=false
ENV CREWAI_STORAGE_DIR=/tmp/crewai
ENV HF_HOME=/tmp/huggingface_cache
ENV TRANSFORMERS_CACHE=/tmp/huggingface_cache
ENV HF_HUB_CACHE=/tmp/huggingface_cache
ENV GRADIO_SERVER_NAME=0.0.0.0
ENV GRADIO_SERVER_PORT=7860
# Create necessary directories
RUN mkdir -p /tmp/crewai
RUN mkdir -p /tmp/huggingface_cache
# Command to run the Gradio app
CMD ["python", "app.py"]
|