32 lines
1.1 KiB
Docker
32 lines
1.1 KiB
Docker
|
|
FROM python:3.11-slim
|
||
|
|
|
||
|
|
WORKDIR /app
|
||
|
|
|
||
|
|
COPY requirements.txt .
|
||
|
|
RUN apt-get update && apt-get -y install git curl ffmpeg libcairo2 libpango-1.0-0 libgdk-pixbuf2.0-0 apt-utils
|
||
|
|
RUN pip install --upgrade pip
|
||
|
|
RUN pip install --no-cache-dir -r requirements.txt
|
||
|
|
RUN pip install PyPDF2 python-multipart gitpython chromadb httpx meilisearch pandas openpyxl python-pptx faster-whisper==1.0.0 cairosvg sentence-transformers rank-bm25
|
||
|
|
|
||
|
|
RUN apt-get update && apt-get install -y --no-install-recommends \
|
||
|
|
wget ca-certificates libstdc++6 libatomic1 \
|
||
|
|
&& rm -rf /var/lib/apt/lists/* \
|
||
|
|
&& mkdir -p /opt/piper \
|
||
|
|
&& set -eux; \
|
||
|
|
URL="https://github.com/rhasspy/piper/releases/download/2023.11.14-2/piper_linux_x86_64.tar.gz"; \
|
||
|
|
wget -O /tmp/piper.tgz "$URL"; \
|
||
|
|
tar -xzf /tmp/piper.tgz -C /opt/piper --strip-components=1; \
|
||
|
|
ln -sf /opt/piper/piper /usr/local/bin/piper; \
|
||
|
|
rm -f /tmp/piper.tgz
|
||
|
|
|
||
|
|
|
||
|
|
COPY app.py .
|
||
|
|
COPY queue_helper.py .
|
||
|
|
COPY agent_repo.py .
|
||
|
|
COPY windowing_utils.py .
|
||
|
|
COPY smart_rag.py .
|
||
|
|
|
||
|
|
EXPOSE 8080
|
||
|
|
|
||
|
|
CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "8080"]
|