FROM python:3.10 # Install necessary packages RUN apt-get update && apt-get install -y curl # Set the working directory WORKDIR /app # Copy application files and requirements COPY . /app COPY ./requirements.txt /app/requirements.txt # Install Python dependencies RUN pip install -r requirements.txt # Install Ollama RUN curl -fsSL https://ollama.com/install.sh | sh # Start Ollama server in the background RUN ollama serve & # Pull the Ollama model RUN ollama pull llama3.2:latest # Set the command to run the Chainlit application CMD ["chainlit", "run", "app.py", "--port", "7860"]