nixfiles/config/services/arrs/default.nix

70 lines
1.9 KiB
Nix
Raw Normal View History

2024-11-12 18:03:31 +01:00
{ lib, pkgs, ... }: {
2024-11-26 12:15:49 +01:00
services = lib.genAttrs [
"sonarr"
"radarr"
"prowlarr"
"lidarr"
] (_: {
2024-11-12 18:03:31 +01:00
enable = true;
});
systemd.services = lib.genAttrs [ "radarr" "sonarr" ] (_: {
2024-11-13 16:03:28 +01:00
wants = [ "mnt-mezzomix.mount" ];
2024-11-12 18:03:31 +01:00
});
2024-12-10 11:46:27 +01:00
nixpkgs.config.permittedInsecurePackages = [
"aspnetcore-runtime-wrapped-6.0.36"
"aspnetcore-runtime-6.0.36"
"dotnet-sdk-wrapped-6.0.428"
"dotnet-sdk-6.0.428"
];
2024-11-12 18:03:31 +01:00
systemd.mounts = lib.singleton {
description = "rclone mount";
after = [ "network.target" ];
wantedBy = [ "multi-user.target" "radarr.service" "sonarr.service" ];
where = "/mnt/mezzomix";
what = "mezzomix@otos.feralhosting.com:private/rtorrent/data";
type = "fuse.sshfs";
2024-11-17 19:25:55 +01:00
options = "umask=0000,idmap=user,_netdev,rw,nosuid,allow_other,default_permissions,follow_symlinks,reconnect,max_conns=10,identityfile=/etc/keys/ssh_host_ed25519_key";
2024-11-12 18:03:31 +01:00
};
systemd.automounts = lib.singleton {
name = "mnt-mezzomix.automount";
where = "/mnt/mezzomix";
wantedBy = [ "multi-user.target" ];
automountConfig.TimeoutIdleSec = 0;
};
environment.systemPackages = [ pkgs.sshfs ];
programs.ssh.ciphers = [ "aes256-ctr" ];
kyouma.nginx.virtualHosts = {
"crime.kyouma.net" = {
verifyClientCert = true;
2024-11-13 16:03:28 +01:00
disableHttp3 = true;
2024-11-12 18:03:31 +01:00
locations = {
2024-11-17 19:25:55 +01:00
"/".root = pkgs.writeTextDir "index.html" (builtins.readFile ./landingPage.html);
2024-11-26 12:15:49 +01:00
"/lidarr/" = {
proxyPass = "http://127.0.0.1:8686";
recommendedProxySettings = true;
};
2024-11-17 19:25:55 +01:00
"/sonarr/" = {
2024-11-12 18:03:31 +01:00
proxyPass = "http://127.0.0.1:8989";
recommendedProxySettings = true;
};
"/radarr/" = {
proxyPass = "http://127.0.0.1:7878";
recommendedProxySettings = true;
};
"/prowlarr/" = {
proxyPass = "http://127.0.0.1:9696";
recommendedProxySettings = true;
};
};
};
};
security.acme.certs."crime.kyouma.net" = {};
}