Why metrics from prometheus are not propagated to custom metrics api via prometheus adapter?

2/8/2020

I have prometheus deployed in my cluster within my custom namespace and prometheus adapter deployed within the same cluster and within the same namespace:

enter image description here

But when I execute:

$ kubectl get --raw /apis/custom.metrics.k8s.io/v1beta1

I see empty response:

{"kind":"APIResourceList","apiVersion":"v1","groupVersion":"custom.metrics.k8s.io/v1beta1","resources":[]}

Although prometheus contains metrics:

enter image description here

I configured prometheus url inside prometheus adapter YML:

enter image description here

How to fix it ?

-- gstackoverflow
google-cloud-platform
google-kubernetes-engine
kubernetes
kubernetes-helm
prometheus

0 Answers