Install k8s-device-plugin on an nvkind cluster
mainOnce your GPU-enabled cluster is running, you must install a device plugin (like k8s-device-plugin or the NVIDIA GPU Operator) to make the GPUs allocatable by Kubernetes pods.
To install the k8s-device-plugin using Helm:
- Add the
nvdpHelm repository. - Set the
KIND_CLUSTER_NAMEenvironment variable to target your cluster. - Run
helm upgrade -itargeting thekind-<cluster-name>context.
# Add repo
helm repo add nvdp https://nvidia.github.io/k8s-device-plugin
helm repo update
# Target cluster
export KIND_CLUSTER_NAME=evenly-distributed-2-by-4
# Install plugin
helm upgrade -i \
--kube-context=kind-${KIND_CLUSTER_NAME} \
--namespace nvidia \
--create-namespace \
nvidia-device-plugin nvdp/nvidia-device-plugin