<p>I have added some labels to kubernetes namespace metadata, now I want to scrape namespace as well as those labels using prometheus, Actually I am trying to create a grafana dashboard and want to categorise namespaces based on labels. I tried using kubernetes_sd_configs, I am able to get namespace but unable to get labels of those namespaces. Does anyone know of any way to scrape labels along with namespace.</p>

Ayush walia
<p>In case somebody is also looking for answer, we can use <a href="http://kubernetes.github.io/kube-state-metrics/" rel="nofollow noreferrer">kube-state-metrics</a></p>
<p>It exposes kube_namespace_labels metric which has labels as well as namespace.</p>
