Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.
Sign upCustom metric path does not work #4052
Comments
This comment has been minimized.
This comment has been minimized.
|
Does the service discovery status page show that __meta_kubernetes_service_annotation_prometheus_io_path is set as you expect? |
This comment has been minimized.
This comment has been minimized.
|
Yes, as of service discovery status page io_path is set to /custom:
|
This comment has been minimized.
This comment has been minimized.
|
Can you share the full relabel configs and the relevant row on the discovery status page? |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
|
I can't reproduce it with v2.2.1, there may be an error with your configuration. |
This comment has been minimized.
This comment has been minimized.
|
Here is the job config (prometheus.yml):
Here are the targets for this job (kubernetes-endpoints): Last target is down, because the metrics are under "/prometheus" not under "/metrics". |
This comment has been minimized.
This comment has been minimized.
|
you've got a typo: the label name should be |
This comment has been minimized.
This comment has been minimized.
|
Omg, thank you! |
brian-brazil
closed this
Apr 6, 2018
This comment has been minimized.
This comment has been minimized.
lock
bot
commented
Mar 22, 2019
|
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |

dbluxo commentedApr 6, 2018
What did you do?
I've configured a custom service inside kubernetes, with the following annotations:
What did you expect to see?
I've configured the following relabel operation inside prometheus.yml, as of:
https://github.com/prometheus/prometheus/blob/master/documentation/examples/prometheus-kubernetes.yml
I'm expecting
__metrics_path__will be replaced with/customWhat did you see instead? Under which circumstances?
__metrics_path__is still/metrics(default)Environment
We are using prometheus 2.2.1 inside kubernetes.
System information:
Linux 4.9.75-rancher x86_64
Prometheus version:
prometheus, version 2.2.1 (branch: HEAD, revision: bc6058c)
build user: root@149e5b3f0829
build date: 20180314-14:15:45
go version: go1.10