From b50f5cd54d287401c8c9bd9cfb4a279c605b8f67 Mon Sep 17 00:00:00 2001 From: Shiv Tyagi Date: Mon, 26 Jan 2026 23:08:59 +0000 Subject: [PATCH] [Fix] Do not mount nicctl to labeller --- internal/nodelabeller/nodelabeller.go | 36 --------------------------- 1 file changed, 36 deletions(-) diff --git a/internal/nodelabeller/nodelabeller.go b/internal/nodelabeller/nodelabeller.go index c201c543..7aa16c36 100644 --- a/internal/nodelabeller/nodelabeller.go +++ b/internal/nodelabeller/nodelabeller.go @@ -75,8 +75,6 @@ func GenerateCommonNodeLabellerSpec(nwConfig *amdv1alpha1.NetworkConfig, isOpenS nlOut.MainContainer.IsPrivileged = true hostPathDirectory := v1.HostPathDirectory - hostPathFileOrCreate := v1.HostPathFileOrCreate - hostPathDirectoryOrCreate := v1.HostPathDirectoryOrCreate nlOut.MainContainer.Envs = []v1.EnvVar{ { @@ -112,16 +110,6 @@ func GenerateCommonNodeLabellerSpec(nwConfig *amdv1alpha1.NetworkConfig, isOpenS MountPath: "/lib/modules", }, } - nonSimMounts := []v1.VolumeMount{ - { - Name: "nicctl", - MountPath: "/usr/sbin/nicctl", - }, - { - Name: "opt-amd", - MountPath: "/opt/amd", - }, - } nlOut.Volumes = []v1.Volume{ { @@ -161,30 +149,6 @@ func GenerateCommonNodeLabellerSpec(nwConfig *amdv1alpha1.NetworkConfig, isOpenS }, }, } - nonSimVolumes := []v1.Volume{ - { - Name: "nicctl", - VolumeSource: v1.VolumeSource{ - HostPath: &v1.HostPathVolumeSource{ - Path: "/usr/sbin/nicctl", - Type: &hostPathFileOrCreate, - }, - }, - }, - { - Name: "opt-amd", - VolumeSource: v1.VolumeSource{ - HostPath: &v1.HostPathVolumeSource{ - Path: "/opt/amd", - Type: &hostPathDirectoryOrCreate, - }, - }, - }, - } - if !simEnabled { - nlOut.MainContainer.VolumeMounts = append(nlOut.MainContainer.VolumeMounts, nonSimMounts...) - nlOut.Volumes = append(nlOut.Volumes, nonSimVolumes...) - } return &nlOut }