Unverified Commit 2e241eb5 authored by Keiven C's avatar Keiven C Committed by GitHub
Browse files

fix: create virtualenv in Dockerfile.sglang dev stage for maturin dev (#3931)


Signed-off-by: default avatarKeiven Chang <keivenchang@users.noreply.github.com>
parent 259b2d39
......@@ -400,6 +400,18 @@ CMD []
FROM runtime AS dev
ARG WORKSPACE_DIR=/sgl-workspace/dynamo
ARG PYTHON_VERSION
# NOTE: SGLang uses system Python (not a virtualenv in framework/runtime stages) to align with
# upstream SGLang Dockerfile: https://github.com/sgl-project/sglang/blob/main/docker/Dockerfile
# For dev stage, we create a lightweight venv with --system-site-packages to satisfy maturin develop
# requirements while still accessing all system-installed packages (sglang, torch, deepep, etc.)
COPY --from=ghcr.io/astral-sh/uv:latest /uv /uvx /bin/
RUN mkdir -p /opt/dynamo/venv && \
uv venv /opt/dynamo/venv --python $PYTHON_VERSION --system-site-packages
ENV VIRTUAL_ENV=/opt/dynamo/venv \
PATH="/opt/dynamo/venv/bin:${PATH}"
# Install development tools and utilities
RUN apt-get update -y && \
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment