nixos-config/machines/orbi/media-arr.nix

114 lines
2.5 KiB
Nix
Raw Normal View History

2023-12-09 17:15:50 +01:00
{ config, ... }:
{
2024-08-29 03:26:04 +02:00
networking.firewall.interfaces.wg0.allowedTCPPorts = [
7878
8989
8686
];
2023-12-09 17:15:50 +01:00
verify.closed.public.ports.arr = [
7878
8989
8686
];
2023-12-09 17:15:50 +01:00
# download series
services.sonarr = {
enable = true;
group = "media";
user = "media";
};
# download movies
services.radarr = {
enable = true;
group = "media";
user = "media";
};
2024-08-05 16:56:42 +02:00
# download music
services.lidarr = {
enable = true;
group = "media";
user = "media";
};
2023-12-09 17:15:50 +01:00
# better indexer apis
services.prowlarr = {
enable = true;
#group = "media";
#user = "media";
};
services.jellyseerr = {
enable = true;
};
services.permown."/media/arr" = {
owner = "media";
group = "media";
directory-mode = "770";
file-mode = "770";
};
services.nginx.virtualHosts = {
"radarr.${config.networking.hostName}.private" = {
2024-04-06 10:34:54 +02:00
serverAliases = [ "radarr.ingolf-wagner.de" ];
2023-12-09 17:15:50 +01:00
extraConfig = ''
allow ${config.tinc.private.subnet};
2024-04-06 10:34:54 +02:00
allow ${config.wireguard.wg0.subnet};
2023-12-09 17:15:50 +01:00
deny all;
'';
locations."/" = {
proxyPass = "http://localhost:7878";
proxyWebsockets = true;
};
};
"sonarr.${config.networking.hostName}.private" = {
2024-04-06 10:34:54 +02:00
serverAliases = [ "sonarr.ingolf-wagner.de" ];
2023-12-09 17:15:50 +01:00
extraConfig = ''
allow ${config.tinc.private.subnet};
2024-04-06 10:34:54 +02:00
allow ${config.wireguard.wg0.subnet};
2023-12-09 17:15:50 +01:00
deny all;
'';
locations."/" = {
proxyPass = "http://localhost:8989";
proxyWebsockets = true;
};
};
2024-08-05 16:56:42 +02:00
"lidarr.${config.networking.hostName}.private" = {
serverAliases = [ "lidarr.ingolf-wagner.de" ];
extraConfig = ''
allow ${config.tinc.private.subnet};
allow ${config.wireguard.wg0.subnet};
deny all;
'';
locations."/" = {
proxyPass = "http://localhost:8686";
proxyWebsockets = true;
};
};
2023-12-09 17:15:50 +01:00
"prowlarr.${config.networking.hostName}.private" = {
extraConfig = ''
allow ${config.tinc.private.subnet};
deny all;
'';
locations."/" = {
proxyPass = "http://localhost:9696";
proxyWebsockets = true;
};
};
"jellyseerr.${config.networking.hostName}.private" = {
extraConfig = ''
allow ${config.tinc.private.subnet};
deny all;
'';
locations."/" = {
proxyPass = "http://localhost:${toString config.services.jellyseerr.port}";
proxyWebsockets = true;
};
};
};
}