feat: add development docker compose (#2411)

This commit is contained in:
Sergio Toro
2025-04-01 12:49:30 +02:00
committed by GitHub
parent aff70807c6
commit 83338295d8
7 changed files with 254 additions and 67 deletions

25
server/dev.Dockerfile Normal file
View File

@@ -0,0 +1,25 @@
FROM python:3.12
WORKDIR /app
# Install Poetry
RUN curl -sSL https://install.python-poetry.org | python3 -
ENV PATH="/root/.local/bin:$PATH"
# Copy requirements first for better caching
COPY server/requirements.txt .
RUN pip install -r requirements.txt
# Install mem0 in editable mode using Poetry
WORKDIR /app/packages
COPY pyproject.toml .
COPY poetry.lock .
COPY README.md .
COPY mem0 ./mem0
RUN pip install -e .[graph]
# Return to app directory and copy server code
WORKDIR /app
COPY server .
CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "8000", "--reload"]