From 62694965d0b17bccf71b76d9bcfa674a32712f33 Mon Sep 17 00:00:00 2001 From: Alejandro Pedraza Date: Tue, 16 Apr 2024 15:07:58 -0500 Subject: [PATCH] Fix 'linkerd version --proxy' --- pkg/k8s/api.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkg/k8s/api.go b/pkg/k8s/api.go index 3e4bd1f69bf9d..8985da427028c 100644 --- a/pkg/k8s/api.go +++ b/pkg/k8s/api.go @@ -323,7 +323,8 @@ func GetProxyReady(pod corev1.Pod) bool { // GetProxyVersion returns the container proxy's version, if any func GetProxyVersion(pod corev1.Pod) string { - for _, container := range pod.Spec.Containers { + containers := append(pod.Spec.InitContainers, pod.Spec.Containers...) + for _, container := range containers { if container.Name == ProxyContainerName { if strings.Contains(container.Image, "@") { // Proxy container image is specified with digest instead of