# Use the official Ollama image as the base FROM docker.io/ollama/ollama:latest # Install Python, pip, and necessary system dependencies (opencv/gradio) RUN apt-get update && \ apt-get install -y --no-install-recommends \ python3 \ python3-pip \ libgl1-mesa-glx && \ apt-get clean && \ rm -rf /var/lib/apt/lists/* # Set the working directory WORKDIR /app # Copy and install Python dependencies (Gradio, Requests, Pillow, etc.) COPY requirements.txt . RUN pip install --no-cache-dir -r requirements.txt # Copy all application files COPY . . # Set the entry point to our startup script ENTRYPOINT ["/bin/bash", "start.sh"]