diff --git a/docker/engine.Dockerfile b/docker/engine.Dockerfile index ccd9f6f6c4..412da8ab0e 100644 --- a/docker/engine.Dockerfile +++ b/docker/engine.Dockerfile @@ -64,9 +64,6 @@ RUN case "${ENGINE}" in \ esac \ && if [ -n "${ENGINE_REPO}" ]; then \ bash /tmp/scripts/install-${ENGINE}.sh /opt/engine-src; \ - fi \ - && if [ "${ENGINE}" = "vllm" ]; then \ - pip install --no-cache-dir smg-grpc-proto "smg-grpc-servicer[vllm]"; \ fi ENTRYPOINT ["smg"] diff --git a/scripts/installation/install-smg.sh b/scripts/installation/install-smg.sh index 61466d0efc..de9e0346b6 100755 --- a/scripts/installation/install-smg.sh +++ b/scripts/installation/install-smg.sh @@ -29,3 +29,11 @@ pip install --no-cache-dir --upgrade pip \ cd "${SMG_SRC}/bindings/python" ulimit -n 65536 && maturin build --release --features vendored-openssl --out dist pip install --force-reinstall dist/*.whl + +# Install smg-grpc-proto and smg-grpc-servicer from source so the image stays +# in sync with this repo. --force-reinstall overrides any stale version the +# engine base image may have preinstalled (e.g. lmsysorg/sglang ships an older +# smg-grpc-servicer pulled from PyPI at its own build time). +pip install --no-cache-dir --force-reinstall \ + "${SMG_SRC}/crates/grpc_client/python" \ + "${SMG_SRC}/grpc_servicer"