Add prometheus exporter for nixarr

This commit is contained in:
Théo Barnouin 2025-05-15 12:25:14 +02:00
parent 543f3bfba4
commit 5fe4d29ce1
7 changed files with 124 additions and 1 deletions

View file

@ -15,6 +15,30 @@ in {
file = ../../secrets/nixarr-lapi-key.age;
owner = "crowdsec";
};
nixarr-radarr-apiKeyFile = {
file = ../../secrets/nixarr-radarr-apiKeyFile.age;
owner = "exportarr-radarr-exporter";
};
nixarr-prowlarr-apiKeyFile = {
file = ../../secrets/nixarr-prowlarr-apiKeyFile.age;
owner = "exportarr-prowlarr-exporter";
};
nixarr-bazarr-apiKeyFile = {
file = ../../secrets/nixarr-bazarr-apiKeyFile.age;
owner = "exportarr-bazarr-exporter";
};
nixarr-sonarr-apiKeyFile = {
file = ../../secrets/nixarr-sonarr-apiKeyFile.age;
owner = "exportarr-sonarr-exporter";
};
};
fileSystems."/downloads" = {
device = "192.168.1.125:/BIGDATA";
fsType = "nfs";
options = [
"x-systemd.automount"
"noauto"
];
};
services = {
crowdsec = {
@ -54,7 +78,35 @@ in {
enable = true;
openFirewall = true;
};
prometheus.exporters = {
exportarr-prowlarr = {
enable = true;
apiKeyFile = "${config.age.secrets.nixarr-prowlarr-apiKeyFile.path}";
openFirewall = true;
};
exportarr-bazarr = {
enable = true;
apiKeyFile = "${config.age.secrets.nixarr-bazarr-apiKeyFile.path}";
openFirewall = true;
};
exportarr-sonarr = {
enable = true;
apiKeyFile = "${config.age.secrets.nixarr-sonarr-apiKeyFile.path}";
openFirewall = true;
};
exportarr-radarr = {
enable = true;
apiKeyFile = "${config.age.secrets.nixarr-radarr-apiKeyFile.path}";
openFirewall = true;
};
};
};
networking = {
firewall.allowedTCPPorts = [3000 9708];
extraHosts = ''
188.114.96.2 www.yggtorrent.top
188.114.97.2 www.yggtorrent.top
'';
};
networking.firewall.allowedTCPPorts = [3000];
};
}