From dc6ebed94dc6a4a7fa9a9af748adc76c06c5c958 Mon Sep 17 00:00:00 2001 From: Joseph Hanson Date: Sun, 21 Apr 2024 05:55:38 -0500 Subject: [PATCH] Reconfigure nvidia device plugin for helmfile use. --- .../nvidia-device-plugin/app/config/config.yml | 9 --------- .../nvidia-device-plugin/app/helmrelease.yaml | 14 +++----------- .../nvidia-device-plugin/app/kustomization.yaml | 4 ++-- .../nvidia-device-plugin/app/resources/values.yml | 10 ++++++++++ 4 files changed, 15 insertions(+), 22 deletions(-) delete mode 100644 kubernetes/apps/kube-system/nvidia-device-plugin/app/config/config.yml create mode 100644 kubernetes/apps/kube-system/nvidia-device-plugin/app/resources/values.yml diff --git a/kubernetes/apps/kube-system/nvidia-device-plugin/app/config/config.yml b/kubernetes/apps/kube-system/nvidia-device-plugin/app/config/config.yml deleted file mode 100644 index 897f6ff7..00000000 --- a/kubernetes/apps/kube-system/nvidia-device-plugin/app/config/config.yml +++ /dev/null @@ -1,9 +0,0 @@ -version: v1 -flags: - migStrategy: "none" - failOnInitError: true - nvidiaDriverRoot: "/" - plugin: - passDeviceSpecs: false - deviceListStrategy: envvar - deviceIDStrategy: uuid diff --git a/kubernetes/apps/kube-system/nvidia-device-plugin/app/helmrelease.yaml b/kubernetes/apps/kube-system/nvidia-device-plugin/app/helmrelease.yaml index 4e5eedb6..f34c1a50 100644 --- a/kubernetes/apps/kube-system/nvidia-device-plugin/app/helmrelease.yaml +++ b/kubernetes/apps/kube-system/nvidia-device-plugin/app/helmrelease.yaml @@ -22,14 +22,6 @@ spec: remediation: retries: 3 strategy: rollback - values: - runtimeClassName: "nvidia" - gfd: - enabled: true - nfd: - enabled: false - resources: - requests: - cpu: 100m - limits: - memory: 512Mi \ No newline at end of file + valuesFrom: + - kind: ConfigMap + name: nvidia-helm-values \ No newline at end of file diff --git a/kubernetes/apps/kube-system/nvidia-device-plugin/app/kustomization.yaml b/kubernetes/apps/kube-system/nvidia-device-plugin/app/kustomization.yaml index 7feac868..c325a94c 100644 --- a/kubernetes/apps/kube-system/nvidia-device-plugin/app/kustomization.yaml +++ b/kubernetes/apps/kube-system/nvidia-device-plugin/app/kustomization.yaml @@ -6,8 +6,8 @@ resources: - ./helmrelease.yaml - ./runtimeclass.yaml configMapGenerator: - - name: nvidia-plugin-configs + - name: nvidia-helm-values files: - - config.yaml=./config/config.yml + - values.yaml=./resources/values.yml generatorOptions: disableNameSuffixHash: true diff --git a/kubernetes/apps/kube-system/nvidia-device-plugin/app/resources/values.yml b/kubernetes/apps/kube-system/nvidia-device-plugin/app/resources/values.yml new file mode 100644 index 00000000..f1ae09e3 --- /dev/null +++ b/kubernetes/apps/kube-system/nvidia-device-plugin/app/resources/values.yml @@ -0,0 +1,10 @@ +runtimeClassName: "nvidia" +gfd: + enabled: true +nfd: + enabled: false +resources: + requests: + cpu: 100m + limits: + memory: 512Mi \ No newline at end of file