Add nvidia device plugin

This commit is contained in:
Joseph Hanson 2024-09-06 21:49:49 -05:00
parent 5775937c46
commit aae1f28c84
Signed by: jahanson
SSH key fingerprint: SHA256:vy6dKBECV522aPAwklFM3ReKAVB086rT3oWwiuiFG7o
6 changed files with 92 additions and 0 deletions

View file

@ -12,5 +12,6 @@ resources:
- ./kubelet-csr-approver/ks.yaml
- ./metrics-server/ks.yaml
- ./node-feature-discovery/ks.yaml
- ./nvidia-device-plugin/ks.yaml
- ./reloader/ks.yaml
- ./spegel/ks.yaml

View file

@ -0,0 +1,42 @@
---
# yaml-language-server: $schema=https://raw.githubusercontent.com/fluxcd-community/flux2-schemas/main/helmrelease-helm-v2beta2.json
apiVersion: helm.toolkit.fluxcd.io/v2
kind: HelmRelease
metadata:
name: nvidia-device-plugin
spec:
interval: 30m
chart:
spec:
chart: nvidia-device-plugin
version: 0.16.2
sourceRef:
kind: HelmRepository
name: nvdp
namespace: flux-system
metadata:
annotations:
reloader.stakater.com/auto: "true"
install:
remediation:
retries: 3
upgrade:
cleanupOnFail: true
remediation:
retries: 3
strategy: rollback
values:
podAnnotations:
configmap.reloader.stakater.com/reload: nvidia-helm-values
config:
name: nvidia-helm-values
runtimeClassName: "nvidia"
gfd:
enabled: true
nfd:
enabled: false
resources:
requests:
cpu: 100m
limits:
memory: 512Mi

View file

@ -0,0 +1,13 @@
---
# yaml-language-server: $schema=https://json.schemastore.org/kustomization
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- ./helmrelease.yaml
- ./runtimeclass.yaml
configMapGenerator:
- name: nvidia-helm-values
files:
- values.yaml=./resources/values.yml
generatorOptions:
disableNameSuffixHash: true

View file

@ -0,0 +1,12 @@
---
version: v1
flags:
migStrategy: "single"
plugin:
deviceListStrategy: "envvar"
deviceIDStrategy: "uuid"
sharing:
timeSlicing:
resources:
- name: nvidia.com/gpu
replicas: 3

View file

@ -0,0 +1,6 @@
---
apiVersion: node.k8s.io/v1
kind: RuntimeClass
metadata:
name: nvidia
handler: nvidia

View file

@ -0,0 +1,18 @@
---
# yaml-language-server: $schema=https://raw.githubusercontent.com/fluxcd-community/flux2-schemas/main/kustomization-kustomize-v1.json
apiVersion: kustomize.toolkit.fluxcd.io/v1
kind: Kustomization
metadata:
name: nvidia-device-plugin
namespace: flux-system
labels:
substitution.flux.home.arpa/enabled: "true"
spec:
targetNamespace: kube-system
interval: 10m
path: "./kubernetes/apps/kube-system/nvidia-device-plugin/app"
prune: true
sourceRef:
kind: GitRepository
name: theshire
wait: true