2024-08-11 09:12:22 +08:00
|
|
|
ARG NIGHTLY_DATE="20240808"
|
2024-06-13 02:53:03 +08:00
|
|
|
ARG BASE_IMAGE="us-central1-docker.pkg.dev/tpu-pytorch-releases/docker/xla:nightly_3.10_tpuvm_$NIGHTLY_DATE"
|
|
|
|
|
|
|
|
FROM $BASE_IMAGE
|
|
|
|
WORKDIR /workspace
|
|
|
|
|
|
|
|
# Install the TPU and Pallas dependencies.
|
2024-08-09 11:24:58 +08:00
|
|
|
RUN python3 -m pip install torch_xla[tpu] -f https://storage.googleapis.com/libtpu-releases/index.html
|
|
|
|
RUN python3 -m pip install torch_xla[pallas] -f https://storage.googleapis.com/jax-releases/jax_nightly_releases.html -f https://storage.googleapis.com/jax-releases/jaxlib_nightly_releases.html
|
2024-07-30 03:42:21 +08:00
|
|
|
|
2024-06-13 02:53:03 +08:00
|
|
|
# Build vLLM.
|
2024-07-09 17:56:06 +08:00
|
|
|
COPY . /workspace/vllm
|
|
|
|
ENV VLLM_TARGET_DEVICE="tpu"
|
2024-08-09 11:24:58 +08:00
|
|
|
RUN cd /workspace/vllm && python3 -m pip install -r requirements-tpu.txt
|
|
|
|
RUN cd /workspace/vllm && python3 setup.py develop
|
2024-06-13 02:53:03 +08:00
|
|
|
|
|
|
|
CMD ["/bin/bash"]
|