feat: finish uv migration (oss + desktop) (#4228)
* migrate desktop and add sqlite as a hard dependency in desktop * migrate oss dockerfile as well
This commit is contained in:
@@ -5,7 +5,6 @@ FROM ankane/pgvector:v0.5.1 AS builder
|
||||
RUN apt-get update && apt-get install -y \
|
||||
python3 \
|
||||
python3-venv \
|
||||
python3-pip \
|
||||
python3-full \
|
||||
build-essential \
|
||||
libpq-dev \
|
||||
@@ -15,7 +14,7 @@ RUN apt-get update && apt-get install -y \
|
||||
ARG LETTA_ENVIRONMENT=DEV
|
||||
ENV LETTA_ENVIRONMENT=${LETTA_ENVIRONMENT} \
|
||||
UV_NO_PROGRESS=1 \
|
||||
UV_PYTHON_PREFERENCE=only-managed \
|
||||
UV_PYTHON_PREFERENCE=system \
|
||||
UV_CACHE_DIR=/tmp/uv_cache
|
||||
|
||||
# Set for other builds
|
||||
@@ -28,8 +27,8 @@ WORKDIR /app
|
||||
RUN python3 -m venv /opt/venv
|
||||
ENV PATH="/opt/venv/bin:$PATH"
|
||||
|
||||
# Now install uv in the virtual environment
|
||||
COPY --from=ghcr.io/astral-sh/uv:latest /uv /usr/local/bin/uv
|
||||
# Now install uv and uvx in the virtual environment
|
||||
COPY --from=ghcr.io/astral-sh/uv:latest /uv /uvx /usr/local/bin/
|
||||
|
||||
|
||||
# Copy dependency files first
|
||||
@@ -37,7 +36,7 @@ COPY apps/core/pyproject.toml apps/core/uv.lock ./
|
||||
# Then copy the rest of the application code
|
||||
COPY . .
|
||||
|
||||
RUN uv sync --frozen --no-dev --no-install-project --all-extras
|
||||
RUN uv sync --frozen --no-dev --no-install-project --all-extras --python 3.11
|
||||
|
||||
# Runtime stage
|
||||
FROM ankane/pgvector:v0.5.1 AS runtime
|
||||
|
||||
@@ -137,6 +137,7 @@ desktop = [
|
||||
"wikipedia>=1.4.0",
|
||||
"langchain-community>=0.3.7",
|
||||
"locust>=2.31.5",
|
||||
"aiosqlite>=0.21.0",
|
||||
"sqlite-vec>=0.1.7a2",
|
||||
"pgvector>=0.2.3",
|
||||
]
|
||||
|
||||
2
uv.lock
generated
2
uv.lock
generated
@@ -2403,6 +2403,7 @@ cloud-tool-sandbox = [
|
||||
{ name = "e2b-code-interpreter" },
|
||||
]
|
||||
desktop = [
|
||||
{ name = "aiosqlite" },
|
||||
{ name = "docker" },
|
||||
{ name = "fastapi" },
|
||||
{ name = "langchain" },
|
||||
@@ -2475,6 +2476,7 @@ sqlite = [
|
||||
requires-dist = [
|
||||
{ name = "aioboto3", marker = "extra == 'bedrock'", specifier = ">=14.3.0" },
|
||||
{ name = "aiomultiprocess", specifier = ">=0.9.1" },
|
||||
{ name = "aiosqlite", marker = "extra == 'desktop'", specifier = ">=0.21.0" },
|
||||
{ name = "aiosqlite", marker = "extra == 'sqlite'", specifier = ">=0.21.0" },
|
||||
{ name = "alembic", specifier = ">=1.13.3" },
|
||||
{ name = "anthropic", specifier = ">=0.49.0" },
|
||||
|
||||
Reference in New Issue
Block a user