From 8b5effda768b2e37234616844df021e8ce9fbc3b Mon Sep 17 00:00:00 2001 From: wangdepeng Date: Tue, 7 May 2024 17:24:53 +0800 Subject: [PATCH] fix: skip spec.nodeName env populated for downwardAPI Signed-off-by: wangdepeng --- pkg/utils/lifted/env.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/pkg/utils/lifted/env.go b/pkg/utils/lifted/env.go index a0999459b..8e36ce05b 100644 --- a/pkg/utils/lifted/env.go +++ b/pkg/utils/lifted/env.go @@ -479,8 +479,9 @@ func podFieldSelectorRuntimeValue(fs *corev1.ObjectFieldSelector, pod *corev1.Po return "", err } switch internalFieldPath { - case "spec.nodeName": - return pod.Spec.NodeName, nil + // skip spec.nodeName populated by vk + //case "spec.nodeName": + // return pod.Spec.NodeName, nil case "spec.serviceAccountName": return pod.Spec.ServiceAccountName, nil }