add client labels to k8s plugin metadata (#6475)

Signed-off-by: Nolan Miles <nolanpmiles@gmail.com>
This commit is contained in:
miles-to-go
2024-03-07 14:34:09 -05:00
committed by GitHub
parent 3d67ee907d
commit 92b7e658e3
5 changed files with 24 additions and 5 deletions

View File

@@ -16,6 +16,7 @@ type Pod struct {
PodIP string
Name string
Namespace string
Labels map[string]string
*Empty
}
@@ -33,6 +34,7 @@ func ToPod(obj meta.Object) (meta.Object, error) {
PodIP: apiPod.Status.PodIP,
Namespace: apiPod.GetNamespace(),
Name: apiPod.GetName(),
Labels: apiPod.GetLabels(),
}
t := apiPod.ObjectMeta.DeletionTimestamp
if t != nil && !(*t).Time.IsZero() {