Mount host NVIDIA libraries into device plugin for NVML access
The device plugin needs libnvidia-ml.so to discover GPUs even when using CDI annotations. Mount /run/opengl-driver/lib (NixOS NVIDIA lib path) into the pod and set LD_LIBRARY_PATH. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
912dfcab10
commit
5194de13b9
1 changed files with 8 additions and 0 deletions
|
|
@ -28,6 +28,8 @@ spec:
|
|||
value: cdi-annotations
|
||||
- name: CDI_ROOT
|
||||
value: /var/run/cdi
|
||||
- name: LD_LIBRARY_PATH
|
||||
value: /run/nvidia/lib
|
||||
securityContext:
|
||||
allowPrivilegeEscalation: false
|
||||
capabilities:
|
||||
|
|
@ -38,6 +40,9 @@ spec:
|
|||
- name: cdi-specs
|
||||
mountPath: /var/run/cdi
|
||||
readOnly: true
|
||||
- name: nvidia-libs
|
||||
mountPath: /run/nvidia/lib
|
||||
readOnly: true
|
||||
volumes:
|
||||
- name: device-plugins
|
||||
hostPath:
|
||||
|
|
@ -45,3 +50,6 @@ spec:
|
|||
- name: cdi-specs
|
||||
hostPath:
|
||||
path: /var/run/cdi
|
||||
- name: nvidia-libs
|
||||
hostPath:
|
||||
path: /run/opengl-driver/lib
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue