mirror of
https://github.com/games-on-whales/gow.git
synced 2026-10-15 12:52:00 +00:00
[PR #353] nvidia-driver: auto-detect host driver version and initialize the volume on start #327
Labels
No labels
bug
enhancement
enhancement
github_actions
good first issue
help wanted
help wanted
invalid
needs testers
pull-request
question
x11-images
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
games-on-whales/gow#327
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/games-on-whales/gow/pull/353
Author: @piotrminkina
Created: 8/2/2026
Status: 🔄 Open
Base:
master← Head:feature/nvidia-auto📝 Commits (2)
6e38893nvidia-driver: auto provide nvidia driver version from the host and automate initialize volume02f8499build-app: allow selecting the default image variant📊 Changes
3 files changed (+36 additions, -8 deletions)
View changed files
📝
bin/build-app.sh(+5 -5)📝
images/nvidia-driver/Dockerfile(+7 -3)➕
images/nvidia-driver/docker-entrypoint.bash(+24 -0)📄 Description
What
Makes the
nvidia-driverimage self-sufficient: it now detects the host driver version at build time and populates the driver volume by itself on container start, instead of requiring the user to passNV_VERSIONmanually and run a separate one-shot container to seed the volume.Changes
images/nvidia-driver/DockerfileNV_VERSIONcan now be supplied through a BuildKit secret mounted at/nvidia-version, falling back to the existingARG NV_VERSIONwhen the secret is absent: This lets Compose feed/sys/module/nvidia/versionstraight from the host, so the image always matches the running kernel driver — no manual version bookkeeping, no drift after a host driver upgrade.FROM scratchtoFROM nvidia-installer, so the image has a usable runtime for the entrypoint.docker-entrypoint.bashasENTRYPOINT.images/nvidia-driver/docker-entrypoint.bash(new)nvidiaandnvidia_uvmmodules are loaded (/proc/modules)nvidia_drmhasmodeset=Y${NV_TARGET_DIR}(default/usr/nvidia.init/) and copies the driver tree from${NV_SOURCE_DIR}(default/usr/nvidia/), so a rebuilt image refreshes the volume rather than layering a new driver over an old one.exec "$@"Both directories are overridable via env vars.
bin/build-app.sh(drive-by, needed to build this image locally)IMAGE_VARIANTnow expands with${2-"-fedora"}instead of${2:-"-fedora"}, so an explicitly empty second argument selects the variant-less (default) images —images/base/buildinstead ofimages/base/build-fedora. Previously''was silently rewritten back to-fedora, which made the default variant unreachable through this script. Omitting the argument still defaults to-fedora, so existing invocations are unaffected.Usage
Intended to run as a Compose init service that Wolf depends on:
Related
Companion documentation PR in the Wolf repository, which adds the Nvidia (Auto) tab to the Quickstart guide describing this workflow: https://github.com/games-on-whales/wolf/pull/470
The two changes are complementary — this PR provides the mechanism, the Wolf PR documents it. The Compose example in the Wolf docs builds from
games-on-whales/gow.git#master, so it only works once this PR is merged.🤖 Generated with Claude Code
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.