Update prometheus/prometheus.yml
This commit is contained in:
@@ -2,13 +2,38 @@ global:
|
|||||||
scrape_interval: 15s
|
scrape_interval: 15s
|
||||||
evaluation_interval: 15s
|
evaluation_interval: 15s
|
||||||
|
|
||||||
|
rule_files:
|
||||||
|
- "/etc/prometheus/alert.rules.yml"
|
||||||
|
|
||||||
scrape_configs:
|
scrape_configs:
|
||||||
# Scrape Prometheus itself
|
# --- Scrape Prometheus itself ---
|
||||||
- job_name: "prometheus"
|
- job_name: "prometheus"
|
||||||
static_configs:
|
static_configs:
|
||||||
- targets: ["prometheus:9090"]
|
- targets: ["prometheus:9090"]
|
||||||
|
|
||||||
# Docker hosts (node_exporter on each)
|
# --- Scrape Alertmanager ---
|
||||||
|
- job_name: "alertmanager"
|
||||||
|
static_configs:
|
||||||
|
- targets: ["alertmanager:9093"]
|
||||||
|
|
||||||
|
# --- Scrape Blackbox Exporter ---
|
||||||
|
- job_name: "blackbox"
|
||||||
|
metrics_path: /probe
|
||||||
|
params:
|
||||||
|
module: [http_2xx] # See blackbox.yml
|
||||||
|
static_configs:
|
||||||
|
- targets:
|
||||||
|
- https://google.com
|
||||||
|
# add https://test.mediakor.com etc. here
|
||||||
|
relabel_configs:
|
||||||
|
- source_labels: [__address__]
|
||||||
|
target_label: __param_target
|
||||||
|
- source_labels: [__param_target]
|
||||||
|
target_label: instance
|
||||||
|
- target_label: __address__
|
||||||
|
replacement: blackbox-exporter:9115
|
||||||
|
|
||||||
|
# --- Docker hosts via node_exporter ---
|
||||||
- job_name: "docker-hosts"
|
- job_name: "docker-hosts"
|
||||||
static_configs:
|
static_configs:
|
||||||
- targets:
|
- targets:
|
||||||
@@ -19,3 +44,15 @@ scrape_configs:
|
|||||||
labels:
|
labels:
|
||||||
env: "prod"
|
env: "prod"
|
||||||
role: "docker-host"
|
role: "docker-host"
|
||||||
|
|
||||||
|
# --- cAdvisor on Docker hosts ---
|
||||||
|
- job_name: "cadvisor"
|
||||||
|
static_configs:
|
||||||
|
- targets:
|
||||||
|
- "172.0.0.199:53801"
|
||||||
|
- "172.0.0.198:53801"
|
||||||
|
- "172.0.0.197:53801"
|
||||||
|
- "172.0.0.196:53801"
|
||||||
|
labels:
|
||||||
|
env: "prod"
|
||||||
|
role: "cadvisor"
|
||||||
|
|||||||
Reference in New Issue
Block a user