Skip to content

Commit

Permalink
Example container using the Nvidia .run installer
Browse files Browse the repository at this point in the history
Signed-off-by: Jonathon Anderson <janderson@ciq.com>
  • Loading branch information
anderbubble committed Jan 6, 2025
1 parent 9ed1301 commit f185edb
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 0 deletions.
1 change: 1 addition & 0 deletions examples/rockylinux-9-nvidia-installer/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
*.run
5 changes: 5 additions & 0 deletions examples/rockylinux-9-nvidia-installer/Containerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
FROM ghcr.io/warewulf/warewulf-rockylinux:9

RUN dnf -y install kernel-devel \
&& dnf clean all \
&& for dir in /usr/src/kernels/*; do /bin/sh /mnt/NVIDIA-Linux.run -X --ui=none --no-backup --no-questions --kernel-name=$(basename $dir); done
20 changes: 20 additions & 0 deletions examples/rockylinux-9-nvidia-installer/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Rocky Linux with the Nvidia driver (.run installer)

This container definition demonstrates building a Rocky Linux based container
incorporating the Nvidia driver from the `.run` installer.

The container may be built with Podman.

```shell

podman build --volume <local .run installer>:/mnt/NVIDIA-Linux.run . --tag rockylinux-9-nvidia-installer
```

This can then be imported directly into Warewulf.

```
wwctl container import $(podman image mount rockylinux-9-nvidia-installer) rockylinux-9-nvidia-installer
podman image unmount rockylinux-9-nvidia-installer
```

The host that builds the container does _not_ need to have a GPU installed.

0 comments on commit f185edb

Please sign in to comment.