diff --git a/deployments/gpu_plugin/base/intel-gpu-plugin.yaml b/deployments/gpu_plugin/base/intel-gpu-plugin.yaml index f793d8457..425479600 100644 --- a/deployments/gpu_plugin/base/intel-gpu-plugin.yaml +++ b/deployments/gpu_plugin/base/intel-gpu-plugin.yaml @@ -24,7 +24,7 @@ spec: allowPrivilegeEscalation: false volumeMounts: - mountPath: /etc/kubernetes/node-feature-discovery/source.d/ - name: nfd-source-hooks + name: nfd-features containers: - name: intel-gpu-plugin env: @@ -58,7 +58,7 @@ spec: - name: kubeletsockets hostPath: path: /var/lib/kubelet/device-plugins - - name: nfd-source-hooks + - name: nfd-features hostPath: path: /etc/kubernetes/node-feature-discovery/source.d/ type: DirectoryOrCreate diff --git a/deployments/sgx_plugin/overlays/epc-hook-initcontainer/add-epc-nfd-initcontainer.yaml b/deployments/sgx_plugin/overlays/epc-hook-initcontainer/add-epc-nfd-initcontainer.yaml index 385dfc0a5..168fa94d4 100644 --- a/deployments/sgx_plugin/overlays/epc-hook-initcontainer/add-epc-nfd-initcontainer.yaml +++ b/deployments/sgx_plugin/overlays/epc-hook-initcontainer/add-epc-nfd-initcontainer.yaml @@ -14,9 +14,9 @@ spec: allowPrivilegeEscalation: false volumeMounts: - mountPath: /etc/kubernetes/node-feature-discovery/source.d/ - name: nfd-source-hooks + name: nfd-features volumes: - - name: nfd-source-hooks + - name: nfd-features hostPath: path: /etc/kubernetes/node-feature-discovery/source.d/ type: DirectoryOrCreate diff --git a/deployments/sgx_plugin/overlays/epc-nfd/add-epc-nfd-initcontainer.yaml b/deployments/sgx_plugin/overlays/epc-nfd/add-epc-nfd-initcontainer.yaml index 385dfc0a5..168fa94d4 100644 --- a/deployments/sgx_plugin/overlays/epc-nfd/add-epc-nfd-initcontainer.yaml +++ b/deployments/sgx_plugin/overlays/epc-nfd/add-epc-nfd-initcontainer.yaml @@ -14,9 +14,9 @@ spec: allowPrivilegeEscalation: false volumeMounts: - mountPath: /etc/kubernetes/node-feature-discovery/source.d/ - name: nfd-source-hooks + name: nfd-features volumes: - - name: nfd-source-hooks + - name: nfd-features hostPath: path: /etc/kubernetes/node-feature-discovery/source.d/ type: DirectoryOrCreate diff --git a/pkg/controllers/gpu/controller.go b/pkg/controllers/gpu/controller.go index 54705d6b4..79c59b3e3 100644 --- a/pkg/controllers/gpu/controller.go +++ b/pkg/controllers/gpu/controller.go @@ -142,7 +142,7 @@ func (c *controller) NewDaemonSet(rawObj client.Object) *apps.DaemonSet { if devicePlugin.Spec.InitImage == "" { daemonSet.Spec.Template.Spec.InitContainers = nil - daemonSet.Spec.Template.Spec.Volumes = removeVolume(daemonSet.Spec.Template.Spec.Volumes, "nfd-source-hooks") + daemonSet.Spec.Template.Spec.Volumes = removeVolume(daemonSet.Spec.Template.Spec.Volumes, "nfd-features") } else { setInitContainer(&daemonSet.Spec.Template.Spec, devicePlugin.Spec.InitImage) } @@ -204,11 +204,11 @@ func setInitContainer(spec *v1.PodSpec, imageName string) { VolumeMounts: []v1.VolumeMount{ { MountPath: "/etc/kubernetes/node-feature-discovery/source.d/", - Name: "nfd-source-hooks", + Name: "nfd-features", }, }, }} - addVolumeIfMissing(spec, "nfd-source-hooks", "/etc/kubernetes/node-feature-discovery/source.d/", v1.HostPathDirectoryOrCreate) + addVolumeIfMissing(spec, "nfd-features", "/etc/kubernetes/node-feature-discovery/source.d/", v1.HostPathDirectoryOrCreate) } func removeVolume(volumes []v1.Volume, name string) []v1.Volume { @@ -246,7 +246,7 @@ func (c *controller) UpdateDaemonSet(rawObj client.Object, ds *apps.DaemonSet) ( if dp.Spec.InitImage == "" { if ds.Spec.Template.Spec.InitContainers != nil { ds.Spec.Template.Spec.InitContainers = nil - ds.Spec.Template.Spec.Volumes = removeVolume(ds.Spec.Template.Spec.Volumes, "nfd-source-hooks") + ds.Spec.Template.Spec.Volumes = removeVolume(ds.Spec.Template.Spec.Volumes, "nfd-features") updated = true } } else { diff --git a/pkg/controllers/sgx/controller.go b/pkg/controllers/sgx/controller.go index 369da3a9c..ce3084159 100644 --- a/pkg/controllers/sgx/controller.go +++ b/pkg/controllers/sgx/controller.go @@ -114,11 +114,11 @@ func setInitContainer(spec *v1.PodSpec, imageName string) { VolumeMounts: []v1.VolumeMount{ { MountPath: "/etc/kubernetes/node-feature-discovery/source.d/", - Name: "nfd-source-hooks", + Name: "nfd-features", }, }, }} - addVolumeIfMissing(spec, "nfd-source-hooks", "/etc/kubernetes/node-feature-discovery/source.d/", v1.HostPathDirectoryOrCreate) + addVolumeIfMissing(spec, "nfd-features", "/etc/kubernetes/node-feature-discovery/source.d/", v1.HostPathDirectoryOrCreate) } func (c *controller) NewDaemonSet(rawObj client.Object) *apps.DaemonSet { @@ -165,7 +165,7 @@ func (c *controller) UpdateDaemonSet(rawObj client.Object, ds *apps.DaemonSet) ( if dp.Spec.InitImage == "" { if ds.Spec.Template.Spec.InitContainers != nil { ds.Spec.Template.Spec.InitContainers = nil - ds.Spec.Template.Spec.Volumes = removeVolume(ds.Spec.Template.Spec.Volumes, "nfd-source-hooks") + ds.Spec.Template.Spec.Volumes = removeVolume(ds.Spec.Template.Spec.Volumes, "nfd-features") updated = true } } else {