Let’s assume I have a metrics endpoint
https://test.metricsource/metrics available. I want metrics from this endpoint to be scraped by fly.io managed prometheus. How can I achieve this?
I am a newbie and saw that we can create an app in the that app’s fly.toml, create an entry for metrics. But not sure about the exact steps. Please help.
The Fly.io global Prometheus service can only scrape Fly.io-hosted apps.
If you want to scrape an external source I think you’d have to set up federation. It might be possible to set up a Prometheus server as a Fly.io app scraping your external source, then have the Fly.io Prometheus scrape that - there are some parameters in federation that cannot be configured in the Fly.io Prometheus though - but you can instead set it up the other way. Have your Prometheus scrape the Fly.io Prometheus’s
federate endpoint, and then your Prometheus can aggregate both the Fly.io-provided metrics and your external sources as desired.
Let me know if these are useful!
Hi @roadmr ,
Can you specify how we can get the Fly.io Prometheus federate endpoint, So that we can use it to scrape its metrics in our setup Prometheus.
You can find information on querying the fly.io metrics here Metrics on Fly.io · Fly Docs