renge/prometheus: Shorten instance name for nodes
This commit is contained in:
parent
0c108d9e44
commit
92bbeffca9
|
@ -71,6 +71,11 @@ in
|
||||||
"shinobu.vpn.sbruder.de:9100"
|
"shinobu.vpn.sbruder.de:9100"
|
||||||
"nazuna.vpn.sbruder.de:9100"
|
"nazuna.vpn.sbruder.de:9100"
|
||||||
];
|
];
|
||||||
|
relabel_configs = lib.singleton {
|
||||||
|
target_label = "instance";
|
||||||
|
source_labels = lib.singleton "__address__";
|
||||||
|
regex = "(.*)\\.vpn\\.sbruder\\.de:9100";
|
||||||
|
};
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
job_name = "qbittorrent";
|
job_name = "qbittorrent";
|
||||||
|
@ -176,7 +181,7 @@ in
|
||||||
rules = map mkAlert [
|
rules = map mkAlert [
|
||||||
{
|
{
|
||||||
name = "InstanceDown";
|
name = "InstanceDown";
|
||||||
expr = ''up{instance!~"(nunotaba|hitagi|mayushii|fuuko).vpn.sbruder.de:.*"} == 0'';
|
expr = ''up{instance!~"(nunotaba|hitagi|mayushii|fuuko)"} == 0'';
|
||||||
description = "Instance {{ $labels.instance }} of job {{ $labels.job }} has been down for more than 1 minutes.";
|
description = "Instance {{ $labels.instance }} of job {{ $labels.job }} has been down for more than 1 minutes.";
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue