2026-06-30 19:41:06 +08:00
|
|
|
# Target vllm version: v0.24.0 (releases/v0.24.0 branch).
|
2026-06-01 11:08:12 +08:00
|
|
|
# The pinned VLLM_PRECOMPILED_WHEEL_COMMIT and VLLM_BASE_TAG below must
|
|
|
|
|
# be updated on every rebase to match the new upstream vllm commit/tag.
|
2025-12-04 23:23:22 +08:00
|
|
|
ARG VLLM_BASE_IMAGE=vllm/vllm-openai
|
2026-07-12 23:39:53 +08:00
|
|
|
ARG VLLM_BASE_TAG=v0.25.0
|
2026-07-22 19:14:55 -06:00
|
|
|
|
|
|
|
|
# We use registry-based layer caching for the dependencies,
|
|
|
|
|
# where the tag is determined based on the hash of the contents
|
|
|
|
|
# of files like pyproject.toml, etc. The deps stage should have
|
|
|
|
|
# everything except the actual project dir, since that should not
|
|
|
|
|
# change much across branches.
|
|
|
|
|
FROM ${VLLM_BASE_IMAGE}:${VLLM_BASE_TAG} AS deps
|
2025-12-04 23:23:22 +08:00
|
|
|
ARG APP_DIR=/workspace/vllm-omni
|
|
|
|
|
WORKDIR ${APP_DIR}
|
2026-07-22 19:14:55 -06:00
|
|
|
|
|
|
|
|
RUN ln -sf /usr/bin/python3 /usr/bin/python
|
|
|
|
|
|
|
|
|
|
# Create a vllm_omni dir so that we can install the python package
|
|
|
|
|
# without failing to write the version files; we'll copy over it
|
|
|
|
|
# after installing
|
|
|
|
|
RUN mkdir -p vllm_omni
|
2026-02-03 13:43:45 +08:00
|
|
|
|
2026-01-16 21:16:43 +08:00
|
|
|
# Install system dependencies
|
|
|
|
|
RUN apt-get update && \
|
2026-04-16 21:24:47 -04:00
|
|
|
apt-get install -y espeak-ng git jq && \
|
2026-02-03 13:43:45 +08:00
|
|
|
apt-get clean && \
|
|
|
|
|
rm -rf /var/lib/apt/lists/*
|
2026-01-16 21:16:43 +08:00
|
|
|
|
2026-07-22 19:14:55 -06:00
|
|
|
# Copy dependency related things first and install deps/
|
|
|
|
|
# We set the version str to 0.0.0 since it doesn't matter
|
|
|
|
|
# for CI
|
|
|
|
|
COPY pyproject.toml setup.py ./
|
|
|
|
|
COPY requirements/ requirements/
|
|
|
|
|
ENV SETUPTOOLS_SCM_PRETEND_VERSION=0.0.0
|
2026-04-04 15:03:32 +08:00
|
|
|
RUN uv pip install --system ".[dev]"
|
2026-02-13 18:05:07 +08:00
|
|
|
|
2026-07-22 19:14:55 -06:00
|
|
|
# The final stage just copies the working dir on top of the
|
|
|
|
|
# dependencies image. This uses --link so that we can skip
|
|
|
|
|
# the image pull in Buildkite when we have a cache hit.
|
|
|
|
|
#
|
|
|
|
|
# IMPORTANT: Do not make any modifications that depend on the
|
|
|
|
|
# file system after the --link copy, otherwise we'd need to pull
|
|
|
|
|
# the heavy base image to build it. This is the reason we copy
|
|
|
|
|
# link & update the pythonpath to point at the copied code instead
|
|
|
|
|
# of running a new pip install on it.
|
|
|
|
|
FROM deps
|
|
|
|
|
ARG APP_DIR=/workspace/vllm-omni
|
|
|
|
|
# Add APP_DIR to the pythonpath, since the entrypoint stub
|
|
|
|
|
# that was installed in the earlier step must point at the copied code.
|
|
|
|
|
#
|
|
|
|
|
# NOTE: this will probably warn about undefined vars, but is expected.
|
|
|
|
|
# See: https://github.com/docker/buildx/issues/2751
|
|
|
|
|
ENV PYTHONPATH=${APP_DIR}${PYTHONPATH:+:${PYTHONPATH}}
|
|
|
|
|
WORKDIR ${APP_DIR}
|
2026-06-14 00:43:02 +08:00
|
|
|
|
2026-07-22 19:14:55 -06:00
|
|
|
COPY --link . .
|
2026-02-03 13:43:45 +08:00
|
|
|
|
2025-12-04 23:23:22 +08:00
|
|
|
ENTRYPOINT []
|