openshift-compatibility#38552
Open
SorenDreano wants to merge 1 commit into
Open
Conversation
Contributor
There was a problem hiding this comment.
Code Review
This pull request introduces a new Docker build stage, vllm-openai-openshift, designed to support OpenShift environments. The changes include setting environment variables for various cache directories to point to /cache and /tmp, creating these directories, and adjusting group permissions to allow group 0 access, which is necessary for OpenShift's arbitrary UID policy. I have no feedback to provide as the review comment was informational and validated the existing implementation's trade-offs.
4 tasks
Contributor
|
This pull request has merge conflicts that must be resolved before it can be |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Purpose
Add a new Dockerfile stage
vllm-openai-openshiftthat produces an OpenShift-compatible variant of thevllm-openaiimage.OpenShift runs containers with an arbitrary non-root UID in group 0. The default image fails because vLLM, HuggingFace, Triton, and other libraries attempt to write to cache/config directories under
$HOMEthat don't exist or aren't writable for arbitrary UIDs.This new image/stage:
/cache/*via environment variables (HF_HOME,VLLM_CACHE_ROOT,TRITON_CACHE_DIR,TORCHINDUCTOR_CACHE_DIR,NUMBA_CACHE_DIR,OUTLINES_CACHE_DIR,VLLM_CONFIG_ROOT,XDG_CACHE_HOME,XDG_CONFIG_HOME)/cacheand$HOMEgroup-0-writable (chgrp -R 0+chmod -R g+rwX)USER 1001so the image never accidentally runs as root outside OpenShift/cache/huggingfaceto persist downloaded modelsTest Plan
docker build --target vllm-openai-openshift -t vllm-openai-openshift .docker run --user 12345:0 vllm-openai-openshift Qwen/Qwen3-VL-2B-InstructTest Result
Manually verified that the image builds and starts without permission errors when run as an arbitrary non-root UID in group 0.
Essential Elements of an Effective PR Description Checklist
supported_models.mdandexamplesfor a new model.