mirror of
https://github.com/davestephens/ansible-nas
synced 2025-01-12 19:48:47 +00:00
Configurable internet speed test interval
This commit is contained in:
parent
21579cc01a
commit
6c24a67d50
2 changed files with 4 additions and 1 deletions
|
@ -49,6 +49,7 @@ stats_grafana_memory: 1g
|
||||||
stats_prometheus_retention_time: 365d
|
stats_prometheus_retention_time: 365d
|
||||||
stats_prometheus_retention_size: 30GB
|
stats_prometheus_retention_size: 30GB
|
||||||
stats_collection_interval: 15s
|
stats_collection_interval: 15s
|
||||||
|
stats_speedtest_collection_interval: 1h
|
||||||
|
|
||||||
# uncomment to scrape more hosts
|
# uncomment to scrape more hosts
|
||||||
# stats_prometheus_additional_hosts:
|
# stats_prometheus_additional_hosts:
|
||||||
|
|
|
@ -35,13 +35,15 @@ scrape_configs:
|
||||||
"{{ hostvars[inventory_hostname]['ansible_default_ipv4']['address'] }}:8083"
|
"{{ hostvars[inventory_hostname]['ansible_default_ipv4']['address'] }}:8083"
|
||||||
]
|
]
|
||||||
|
|
||||||
|
{% if stats_internet_speed_test_enabled %}
|
||||||
- job_name: "speedtest"
|
- job_name: "speedtest"
|
||||||
scrape_interval: 1h
|
scrape_interval: {{ stats_speedtest_collection_interval }}
|
||||||
scrape_timeout: 5m
|
scrape_timeout: 5m
|
||||||
static_configs:
|
static_configs:
|
||||||
- targets: [
|
- targets: [
|
||||||
"{{ hostvars[inventory_hostname]['ansible_default_ipv4']['address'] }}:{{ stats_speedtest_exporter_port }}"
|
"{{ hostvars[inventory_hostname]['ansible_default_ipv4']['address'] }}:{{ stats_speedtest_exporter_port }}"
|
||||||
]
|
]
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
{% if stats_prometheus_additional_hosts is defined %}
|
{% if stats_prometheus_additional_hosts is defined %}
|
||||||
- job_name: "additional_hosts"
|
- job_name: "additional_hosts"
|
||||||
|
|
Loading…
Reference in a new issue