Use a blackbox with custom DNS rather than proxy
This makes timing information more relevant and should improve reliability
This commit is contained in:
parent
772cf7536a
commit
bb4361e25f
3 changed files with 19 additions and 16 deletions
|
@ -3,13 +3,6 @@ modules:
|
||||||
prober: http
|
prober: http
|
||||||
timeout: 10s
|
timeout: 10s
|
||||||
|
|
||||||
http_external:
|
|
||||||
prober: http
|
|
||||||
timeout: 10s
|
|
||||||
http:
|
|
||||||
proxy_url: http://{{ pve_hosts.qbittorrent.ip }}:3128
|
|
||||||
skip_resolve_phase_with_proxy: true
|
|
||||||
|
|
||||||
https_redir:
|
https_redir:
|
||||||
prober: http
|
prober: http
|
||||||
timeout: 10s
|
timeout: 10s
|
||||||
|
|
|
@ -1,5 +1,12 @@
|
||||||
version: "2.3"
|
version: "2.3"
|
||||||
|
|
||||||
|
x-blackbox: &blackbox
|
||||||
|
image: prom/blackbox-exporter:latest
|
||||||
|
restart: unless-stopped
|
||||||
|
user: "{{ docker_user.id }}"
|
||||||
|
volumes:
|
||||||
|
- ./blackbox.yml:/etc/blackbox_exporter/config.yml:ro
|
||||||
|
|
||||||
services:
|
services:
|
||||||
prometheus:
|
prometheus:
|
||||||
image: prom/prometheus:latest
|
image: prom/prometheus:latest
|
||||||
|
@ -15,11 +22,14 @@ services:
|
||||||
- "{{ pve_hosts.forrest.ip }}:9090:9090"
|
- "{{ pve_hosts.forrest.ip }}:9090:9090"
|
||||||
|
|
||||||
blackbox:
|
blackbox:
|
||||||
image: prom/blackbox-exporter:latest
|
<<: *blackbox
|
||||||
restart: unless-stopped
|
|
||||||
user: "{{ docker_user.id }}"
|
blackbox-external:
|
||||||
volumes:
|
<<: *blackbox
|
||||||
- ./blackbox.yml:/etc/blackbox_exporter/config.yml:ro
|
# Don't use my internal DNS servers
|
||||||
|
dns:
|
||||||
|
- 9.9.9.9
|
||||||
|
- 149.112.112.112
|
||||||
|
|
||||||
alertmanager:
|
alertmanager:
|
||||||
image: prom/alertmanager:latest
|
image: prom/alertmanager:latest
|
||||||
|
|
|
@ -40,7 +40,7 @@ scrape_configs:
|
||||||
scrape_interval: 1m
|
scrape_interval: 1m
|
||||||
metrics_path: /probe
|
metrics_path: /probe
|
||||||
params:
|
params:
|
||||||
module: [http_external]
|
module: [http]
|
||||||
static_configs:
|
static_configs:
|
||||||
- targets:
|
- targets:
|
||||||
- https://bin.theorangeone.net
|
- https://bin.theorangeone.net
|
||||||
|
@ -64,7 +64,7 @@ scrape_configs:
|
||||||
- source_labels: [__param_target]
|
- source_labels: [__param_target]
|
||||||
target_label: instance
|
target_label: instance
|
||||||
- target_label: __address__
|
- target_label: __address__
|
||||||
replacement: blackbox:9115
|
replacement: blackbox-external:9115
|
||||||
|
|
||||||
- job_name: blackbox_https_redir
|
- job_name: blackbox_https_redir
|
||||||
scrape_interval: 10m
|
scrape_interval: 10m
|
||||||
|
@ -80,13 +80,13 @@ scrape_configs:
|
||||||
- source_labels: [__param_target]
|
- source_labels: [__param_target]
|
||||||
target_label: instance
|
target_label: instance
|
||||||
- target_label: __address__
|
- target_label: __address__
|
||||||
replacement: blackbox:9115
|
replacement: blackbox-external:9115
|
||||||
|
|
||||||
- job_name: blackbox_healthcheck
|
- job_name: blackbox_healthcheck
|
||||||
scrape_interval: 10m
|
scrape_interval: 10m
|
||||||
metrics_path: /probe
|
metrics_path: /probe
|
||||||
params:
|
params:
|
||||||
module: [http_external]
|
module: [http]
|
||||||
static_configs:
|
static_configs:
|
||||||
- targets:
|
- targets:
|
||||||
- https://hc-ping.com/{{ prometheus_healthcheck_uuid }}
|
- https://hc-ping.com/{{ prometheus_healthcheck_uuid }}
|
||||||
|
|
Loading…
Reference in a new issue