Table-aware-RAG / Dockerfile
anindya-hf-2002's picture
Update Dockerfile
e3a36bf verified
raw
history blame contribute delete
874 Bytes
# Use Python slim image as base
FROM python:3.10-slim
# Install system dependencies and wget (for downloading Ollama)
RUN apt-get update && \
apt-get install -y \
curl \
procps \
git \
wget \
lsof && \
rm -rf /var/lib/apt/lists/*
# Set working directory
WORKDIR /app
# Copy project files
COPY requirements.txt .
COPY src/ ./src/
COPY *.py ./
COPY execute.sh ./execute.sh
# Install Python dependencies
RUN pip install --no-cache-dir -r requirements.txt
# Set Python path
ENV PYTHONPATH=/app
# Create directory for Ollama models
RUN mkdir -p /root/.ollama
# Expose ports for both Streamlit and Ollama
EXPOSE 80
# Make sure execute.sh is executable
RUN chmod +x ./execute.sh
# Adjust execute.sh to start Streamlit on port 80
RUN sed -i 's/--server.port 8501/--server.port 80/g' execute.sh
# Set the entrypoint
ENTRYPOINT ["./execute.sh"]