2025-01-24 23:23:03 -08:00
|
|
|
ARG NIGHTLY_DATE="20250124"
|
2024-06-12 11:53:03 -07:00
|
|
|
ARG BASE_IMAGE="us-central1-docker.pkg.dev/tpu-pytorch-releases/docker/xla:nightly_3.10_tpuvm_$NIGHTLY_DATE"
|
|
|
|
|
|
|
|
FROM $BASE_IMAGE
|
2024-10-17 19:25:06 +02:00
|
|
|
WORKDIR /workspace/vllm
|
2024-06-12 11:53:03 -07:00
|
|
|
|
2024-09-11 13:21:36 +08:00
|
|
|
# Install some basic utilities
|
2024-09-23 18:44:26 +02:00
|
|
|
RUN apt-get update && apt-get install -y \
|
|
|
|
git \
|
|
|
|
ffmpeg libsm6 libxext6 libgl1
|
2024-09-11 13:21:36 +08:00
|
|
|
|
2024-06-12 11:53:03 -07:00
|
|
|
# Build vLLM.
|
2024-10-17 19:25:06 +02:00
|
|
|
COPY . .
|
|
|
|
ARG GIT_REPO_CHECK=0
|
|
|
|
RUN --mount=type=bind,source=.git,target=.git \
|
|
|
|
if [ "$GIT_REPO_CHECK" != 0 ]; then bash tools/check_repo.sh; fi
|
|
|
|
|
2024-07-09 02:56:06 -07:00
|
|
|
ENV VLLM_TARGET_DEVICE="tpu"
|
2024-09-23 18:44:26 +02:00
|
|
|
RUN --mount=type=cache,target=/root/.cache/pip \
|
|
|
|
--mount=type=bind,source=.git,target=.git \
|
|
|
|
python3 -m pip install \
|
2025-03-08 17:44:35 +01:00
|
|
|
-r requirements/tpu.txt
|
2024-10-17 19:25:06 +02:00
|
|
|
RUN python3 setup.py develop
|
2024-06-12 11:53:03 -07:00
|
|
|
|
2024-11-26 00:20:04 -08:00
|
|
|
# install development dependencies (for testing)
|
|
|
|
RUN python3 -m pip install -e tests/vllm_test_utils
|
|
|
|
|
2024-06-12 11:53:03 -07:00
|
|
|
CMD ["/bin/bash"]
|