|
@@ -9,11 +9,22 @@ global:
|
|
# A scrape configuration containing exactly one endpoint to scrape:
|
|
# A scrape configuration containing exactly one endpoint to scrape:
|
|
# Here it's Prometheus itself.
|
|
# Here it's Prometheus itself.
|
|
scrape_configs:
|
|
scrape_configs:
|
|
- # The job name is added as a label `job=<job_name>` to any timeseries scraped from this config.
|
|
|
|
- - job_name: 'prometheus'
|
|
|
|
-
|
|
|
|
- # Override the global default and scrape targets from this job every 5 seconds.
|
|
|
|
|
|
+ - job_name: 'supernodes'
|
|
|
|
+ scheme: https
|
|
|
|
+ bearer_token: '{{ hostvars[groups['supernodes'][0]]['node_exporter_authorization_token'] }}'
|
|
scrape_interval: 5s
|
|
scrape_interval: 5s
|
|
|
|
+ static_configs:
|
|
|
|
+ - targets:
|
|
|
|
+{% for host in groups['supernodes'] %}
|
|
|
|
+ - '{{ host }}'
|
|
|
|
+{% endfor %}
|
|
|
|
|
|
|
|
+ - job_name: 'mapservers'
|
|
|
|
+ scheme: https
|
|
|
|
+ bearer_token: '{{ hostvars[groups['mapservers'][0]]['node_exporter_authorization_token'] }}'
|
|
|
|
+ scrape_interval: 5s
|
|
static_configs:
|
|
static_configs:
|
|
- - targets: ['localhost:9090']
|
|
|
|
|
|
+ - targets:
|
|
|
|
+{% for host in groups['mapservers'] %}
|
|
|
|
+ - '{{ host }}'
|
|
|
|
+{% endfor %}
|