Collect your own Premetheus exporter metrics to Grafana Cloud with Grafana agent
scrape_configs
Assume you have grafana agent installed on your server and your own Premetheus exporter run on 127.0.0.1:5000/metrics
, edit /etc/grafana-agent.yaml
and add the following configs after scrape_configs
scrape_configs:
- job_name: 'My-Own-Metrics'
static_configs:
- targets: ['127.0.0.1:5000']
Then restart grafana agent, you’ll see your own metrics in grafana cloud.
sudo systemctl status grafana-agent.service
Reference
https://prometheus.io/docs/prometheus/2.34/configuration/configuration/#scrape_config
Back to Table of Contents
Disclaimer
- License under
CC BY-NC 4.0
- Copyright issue feedback
me#imzye.com
, replace # with @ - Not all the commands and scripts are tested in production environment, use at your own risk
- No personal information is collected.
Feedback