<p>I'm trying to get the ip address of pods with particular label using jsonpath with the following command:</p>
<p><code>kubectl get pods -l app=validate -n {namespace_name} -o jsonpath={.status.podIP}</code></p>
<p>But this doesn't result into anything, even though the namespace and label names are correct. On the other hand, if I try to do:</p>
<p><code>kubectl get pod/pod_name -n {namespace_name} -o jsonpath={.status.podIP}</code></p>
<p>I'm able to get the pod IP address after that. But the problem is, since I'm trying to query all the pods created for a particular deployment, I want to fetch Ip addresses for all the pods under that particular label. I'm not sure what is wrong with the command.</p>

<p>If you have multiple Pods with the same label, you get a list of Pods. You have to adjust your jsonpath to <code> -o jsonpath=&quot;{.items[*].status.podIP}&quot;</code> to get all the podIPs.</p>
