Add vespa user to root group for OpenShift arbitrary UID support#357
Open
snecklifter wants to merge 1 commit intovespa-engine:mainfrom
Open
Add vespa user to root group for OpenShift arbitrary UID support#357snecklifter wants to merge 1 commit intovespa-engine:mainfrom
snecklifter wants to merge 1 commit intovespa-engine:mainfrom
Conversation
OpenShift's restricted-v2 SCC assigns arbitrary UIDs with GID 0 (root group). Adding the vespa user to the root group ensures compatibility if these dev images are used as bases for OpenShift deployments. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
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.
Summary
vespauser to the root group (-G root) in the two dev image Dockerfiles that create this userBackground: OpenShift SCCs and the root group
OpenShift 4.20's default
restricted-v2SCC runs containers with arbitrary UIDs that are always members of GID 0 (root group). As the OpenShift image guidelines state:Using GID 0 as the group does not grant root privileges — the root group is simply the access mechanism for arbitrary UIDs, while the root user (UID 0) remains prohibited.
Scope
Only the two dev Dockerfiles that create a
vespauser are affected:dev/almalinux-8/Dockerfile—useraddnow includes-G rootdev/almalinux-9/Dockerfile— sameWhat was NOT changed (and why)
build/Dockerfiles: Don't create a vespa user — purely build environmentsdebug-dev/: Inherits fromvespa-dev-almalinux-8, no user creationcreate-and-start.sh/configure-container.shscripts: These run on the host viadocker execas root to configure dev containers. They operate outside OpenShift's security model and are not affected by SCC restrictionsdocker-swarm/: CI infrastructure, not deployed on OpenShiftexperimental/anduniversity/: Training/experimental images with fundamentally different security models (sudo access, interactive users)Test plan
dev/almalinux-8anddev/almalinux-9imagesid vespashowsrootin the groups list🤖 Generated with Claude Code