geerlingguy / internet-pi

Raspberry Pi config for all things Internet.
MIT License
4.29k stars 448 forks source link

Allow addition of extra prometheus scrape_configs #443

Closed geerlingguy closed 1 year ago

geerlingguy commented 1 year ago

I want to monitor my ASUS router (working on a blog post on the process of getting node_exporter running on it now), and so I want to add a Prometheus job in the scrape_configs. Right now this project just has a hardcoded list in prometheus.yml. That's silly!

So I want to add a variable, prometheus_extra_scrape_configs, to allow additional configs to be added, like:

prometheus_extra_scrape_configs: |
  - job_name: 'asusrouter'
    scrape_interval: 5s
    static_configs:
      - targets: ['10.0.100.1:9100']