Skip to content

Commit

Permalink
Allow custom NVIDIA CTK path
Browse files Browse the repository at this point in the history
  • Loading branch information
empovit committed Feb 12, 2024
1 parent 255f9c7 commit e6eab1d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions cmd/nvidia-dra-plugin/cdi.go
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,7 @@ func NewCDIHandler(opts ...cdiOption) (*CDIHandler, error) {
nvcdi.WithMode("nvml"),
nvcdi.WithVendor(h.vendor),
nvcdi.WithClass(h.class),
nvcdi.WithNVIDIACTKPath(h.nvidiaCTKPath),
)
if err != nil {
return nil, fmt.Errorf("unable to create CDI library: %w", err)
Expand Down
2 changes: 2 additions & 0 deletions deployments/helm/k8s-dra-driver/templates/kubeletplugin.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,8 @@ spec:
resources:
{{- toYaml .Values.kubeletPlugin.containers.plugin.resources | nindent 10 }}
env:
- name: NVIDIA_CTK_PATH
value: "{{ .Values.nvidiaCtkPath }}"
- name: NVIDIA_DRIVER_ROOT
value: "{{ .Values.nvidiaDriverRoot }}"
- name: NVIDIA_VISIBLE_DEVICES
Expand Down

0 comments on commit e6eab1d

Please sign in to comment.