mikrotik_monitoring/prometheus/prometheus.yml

51 lines
1.6 KiB
YAML
Raw Normal View History

2021-07-10 14:56:26 +02:00
# my global config
global:
scrape_interval: 120s # By default, scrape targets every 15 seconds.
evaluation_interval: 120s # By default, scrape targets every 15 seconds.
# scrape_timeout is set to the global default (10s).
# Attach these labels to any time series or alerts when communicating with
# external systems (federation, remote storage, Alertmanager).
external_labels:
2023-02-26 13:32:53 +01:00
monitor: 'mikrotik-monitoring'
2021-07-10 14:56:26 +02:00
# Load and evaluate rules in this file every 'evaluation_interval' seconds.
rule_files:
# - "alert.rules"
# - "first.rules"
# - "second.rules"
# A scrape configuration containing exactly one endpoint to scrape:
# Here it's Prometheus itself.
scrape_configs:
# The job name is added as a label `job=<job_name>` to any timeseries scraped from this config.
2023-03-05 15:37:44 +01:00
- job_name: 'mikrotik'
2021-07-10 14:56:26 +02:00
# Override the global default and scrape targets from this job every 5 seconds.
scrape_interval: 15s
2021-07-10 14:56:26 +02:00
# metrics_path defaults to '/metrics'
# scheme defaults to 'http'.
static_configs:
- targets:
- 'mktxp:49090'
2023-03-05 15:37:44 +01:00
- job_name: 'blackbox'
scrape_interval: 1s
metrics_path: /probe
params:
module: [icmp_ttl5] # use ICMP as the ping protocol
static_configs:
- targets:
- 1.1.1.1
- 8.8.8.8
- 9.9.9.9
relabel_configs:
- source_labels: [__address__]
target_label: __param_target
- source_labels: [__param_target]
target_label: instance
- target_label: __address__
replacement: blackbox:9115 # The blackbox exporter's real hostname:port.