@@ -58,7 +58,7 @@ RUN --mount=type=cache,target=/root/.cache/uv \
5858 cd ../../python && \
5959 export PYARROW_PARALLEL=4 && \
6060 export ARROW_BUILD_TYPE=release && \
61- uv pip install -r requirements/ build.txt && \
61+ uv pip install -r requirements- build.txt && \
6262 python setup.py build_ext --build-type=$ARROW_BUILD_TYPE --bundle-arrow-cpp bdist_wheel
6363
6464FROM python-install AS numa-build
@@ -96,6 +96,22 @@ RUN --mount=type=cache,target=/root/.cache/uv \
9696 uv pip install -v torch==${TORCH_VERSION} --extra-index-url https://download.pytorch.org/whl/nightly/cpu && \
9797 python setup.py bdist_wheel
9898
99+ FROM python-install AS hf-xet-builder
100+ # Install hf-xet
101+ WORKDIR /tmp
102+ ENV CARGO_HOME=/root/.cargo
103+ ENV RUSTUP_HOME=/root/.rustup
104+ ENV PATH="$CARGO_HOME/bin:$RUSTUP_HOME/bin:$PATH"
105+ RUN --mount=type=cache,target=/root/.cache/uv \
106+ --mount=type=bind,from=rust,source=/root/.cargo,target=/root/.cargo,rw \
107+ --mount=type=bind,from=rust,source=/root/.rustup,target=/root/.rustup,rw \
108+ git clone https://github.com/huggingface/xet-core.git && \
109+ cd xet-core/hf_xet/ && \
110+ uv pip install maturin patchelf && \
111+ python -m maturin build --release --out dist && \
112+ mkdir -p /tmp/hf-xet/dist && \
113+ cp dist/*.whl /tmp/hf-xet/dist/
114+
99115# Final build stage
100116FROM python-install AS vllm-cpu
101117ARG PYTHON_VERSION
@@ -120,12 +136,15 @@ RUN --mount=type=cache,target=/root/.cache/uv \
120136 --mount=type=bind,from=rust,source=/root/.rustup,target=/root/.rustup,rw \
121137 --mount=type=bind,from=pyarrow,source=/tmp/arrow/python/dist,target=/tmp/arrow-wheels \
122138 --mount=type=bind,from=torch-vision,source=/tmp/vision/dist,target=/tmp/vision-wheels/ \
139+ --mount=type=bind,from=hf-xet-builder,source=/tmp/hf-xet/dist,target=/tmp/hf-xet-wheels/ \
123140 sed -i '/^torch/d' requirements/build.txt && \
124141 ARROW_WHL_FILE=$(ls /tmp/arrow-wheels/pyarrow-*.whl | head -n 1) && \
125142 VISION_WHL_FILE=$(ls /tmp/vision-wheels/*.whl | head -n 1) && \
143+ HF_XET_WHL_FILE=$(ls /tmp/hf-xet-wheels/*.whl | head -n 1) && \
126144 uv pip install -v \
127145 $ARROW_WHL_FILE \
128146 $VISION_WHL_FILE \
147+ $HF_XET_WHL_FILE \
129148 --extra-index-url https://download.pytorch.org/whl/nightly/cpu \
130149 --index-strategy unsafe-best-match \
131150 -r requirements/build.txt \
@@ -149,4 +168,5 @@ USER 2000
149168WORKDIR /home/vllm
150169
151170# Set the default entrypoint
152- ENTRYPOINT ["python", "-m", "vllm.entrypoints.openai.api_server"]
171+ ENTRYPOINT ["python", "-m", "vllm.entrypoints.openai.api_server"]
172+
0 commit comments