1
0
Fork 0
mirror of https://github.com/kubernetes-sigs/node-feature-discovery.git synced 2024-12-14 11:57:51 +00:00

nfd-master: correctly clean up annotations

Delete correct annotations if -instance is specified.
This commit is contained in:
Markus Lehtonen 2023-10-05 11:10:06 +03:00
parent 7f6fd05357
commit 9ea0a1b420

View file

@ -1065,7 +1065,9 @@ func (m *nfdMaster) updateNodeObject(cli *kubernetes.Clientset, nodeName string,
patches := createPatches(oldLabels, node.Labels, labels, "/metadata/labels")
patches = append(patches,
createPatches(
[]string{nfdv1alpha1.FeatureLabelsAnnotation, nfdv1alpha1.ExtendedResourceAnnotation},
[]string{
m.instanceAnnotation(nfdv1alpha1.FeatureLabelsAnnotation),
m.instanceAnnotation(nfdv1alpha1.ExtendedResourceAnnotation)},
node.Annotations,
annotations,
"/metadata/annotations")...)