1
Fork 0
mirror of https://github.com/RGBCube/ncc synced 2025-07-30 11:37:44 +00:00

Add scrape configs

This commit is contained in:
RGBCube 2024-01-12 19:13:46 +03:00
parent 1cbea6a67a
commit 336c7d3832
No known key found for this signature in database
3 changed files with 35 additions and 0 deletions

View file

@ -28,6 +28,20 @@ in serverSystemConfiguration {
};
};
services.prometheus.scrapeConfigs = [{
job_name = "mail";
static_configs = [{
labels = [ "mail" ];
targets = [
"[::]:${toString config.services.prometheus.exporters.dmarc.port}"
"[::]:${toString config.services.prometheus.exporters.dovecot.port}"
"[::]:${toString config.services.prometheus.exporters.postfix.port}"
"[::]:${toString config.services.prometheus.exporters.rspamd.port}"
];
}];
}];
mailserver = enabled {
inherit fqdn;

View file

@ -13,6 +13,18 @@ serverSystemConfiguration {
};
};
services.prometheus.scrapeConfigs = [{
job_name = "nginx";
static_configs = [{
labels = [ "nginx" ];
targets = [
"[::]:${toString config.services.prometheus.exporters.nginxlog.port}"
"[::]:${toString config.services.prometheus.exporters.nginx.port}"
];
}];
}];
services.nginx = enabled {
statusPage = true;

View file

@ -8,5 +8,14 @@ serverSystemConfiguration {
enabledCollectors = [ "systemd" ];
port = 9001;
};
scrapeConfigs = [{
job_name = "node";
static_configs = [{
labels = [ "node" ];
targets = [ "[::]:${toString config.services.prometheus.exporters.node.port}" ];
}];
}];
};
}