From a0b65b72912984dc71a71954f75d15474a593973 Mon Sep 17 00:00:00 2001 From: Malte Tammena Date: Sat, 17 Feb 2024 14:22:08 +0100 Subject: [PATCH] feat(faunus-ater): prowlarr and media fixes --- hosts/faunus-ater/modules/media.nix | 31 +++++++++++++++++++++++++- secrets/hosts/faunus-ater/secrets.yaml | 5 +++-- secrets/pub/prowlarr-tammena-me.crt | 12 ++++++++++ 3 files changed, 45 insertions(+), 3 deletions(-) create mode 100644 secrets/pub/prowlarr-tammena-me.crt diff --git a/hosts/faunus-ater/modules/media.nix b/hosts/faunus-ater/modules/media.nix index f88ccea..02d05a8 100644 --- a/hosts/faunus-ater/modules/media.nix +++ b/hosts/faunus-ater/modules/media.nix @@ -36,12 +36,34 @@ in { group = "media"; }; + # Bazarr for subtitles + services.prowlarr = { + enable = true; + package = pkgs.prowlarr.overrideAttrs (old: let + version = lib.warnIfNot (old.version == "1.10.5.4116") "Prowlarr was updated!" "1.13.3.4273"; + arch = + { + aarch64-darwin = "arm64"; + aarch64-linux = "arm64"; + x86_64-darwin = "x64"; + x86_64-linux = "x64"; + } + .${pkgs.stdenv.hostPlatform.system}; + in { + inherit version; + src = pkgs.fetchurl { + url = "https://github.com/Prowlarr/Prowlarr/releases/download/v${version}/Prowlarr.master.${version}.linux-core-${arch}.tar.gz"; + hash = "sha256-8yESqqILrYZXhOPXLrlEVkQca0MYRfzKO+GtFqyLeGs="; + }; + }); + }; + # Sabnzbd for usenet services.sabnzbd = { enable = true; group = "media"; package = pkgs.sabnzbd.overrideAttrs (old: rec { - version = builtins.trace "Was sabnzbd updated?" "4.2.2"; + version = lib.warnIfNot (old.version == "4.2.1") "Sabnzbd was updated!" "4.2.2"; src = pkgs.fetchFromGitHub { owner = old.pname; repo = old.pname; @@ -121,6 +143,12 @@ in { proxyWebsockets = true; }; }; + "prowlarr.tammena.me" = withPreset "prowlarr" { + locations."/" = { + proxyPass = "http://127.0.0.1:9696"; + proxyWebsockets = true; + }; + }; "downloadarr.tammena.me" = withPreset "downloadarr" { locations."/" = { proxyPass = "http://127.0.0.1:8080"; @@ -145,6 +173,7 @@ in { certificate-key-radarr-tammena-me = conf; certificate-key-sonarr-tammena-me = conf; certificate-key-bazarr-tammena-me = conf; + certificate-key-prowlarr-tammena-me = conf; certificate-key-downloadarr-tammena-me = conf; certificate-key-webdav-tammena-me = conf; }; diff --git a/secrets/hosts/faunus-ater/secrets.yaml b/secrets/hosts/faunus-ater/secrets.yaml index a953628..e24a341 100644 --- a/secrets/hosts/faunus-ater/secrets.yaml +++ b/secrets/hosts/faunus-ater/secrets.yaml @@ -23,6 +23,7 @@ certificate-key-sonarr-tammena-me: ENC[AES256_GCM,data:WmzTf2ywMCWx6SrnOJFSgEwy8 certificate-key-downloadarr-tammena-me: ENC[AES256_GCM,data:BqXzsbgq1Ir9jNFONg4YjDYjpfu5fa3/ZyE+NutU60gc9SBTPam/uT70ml65QS6OoKSw5cz/z1YjowUpfXIKuasMe2VVFPreHEMwV0vKRHOXvSIrJS58YEDKQYi1ROgfZz5JPkbvtdsOLPdEmYuBKqcLuVZg69IzoRFWi47Guiwlj3hwL40AHrOOZC0YZdb749LqrveuuO2qImku4Bl4hDn0px5nVm56AZKuqhgxWeN9gQNoFIT+1bIG+3WN04/vijP2ect/OtHs+6MSNtnZ+ayNm6Y6ilSIEnJsW4+jyefv/GEPQmXN3oQnIBcyvVXjmgmIT5aQbU6B6uMOFtmDy8qfoGrAGcPYPq2DRln79hUGzqTcwOjpTQ2jr0eAqqBj30GSR8MgrIKCz7tOaN4=,iv:OLST42go9AxZ2PvcWp5oNIrhDBkLYeKvZukF5saLzrQ=,tag:R9gmKx7un3531uc8PM0gtg==,type:str] certificate-key-webdav-tammena-me: ENC[AES256_GCM,data:XdX1uSK5H/8SnqrLraTEY++2a5YUy5H67XM+7ap2F7Y6bShxHWTUrb0MK/d/ZX5SM9F1NCchPyJPeI2gFCqxVWkFmvt6b4q3TyleLX3LCAHHcESvwc3HCNiMs4ceFPlHheJRzc5dExoGFZ34ARYd2zaIPvWVcsN06XhaoShjVUEcD7EOrzZL57GTS6Gx2RbTfXn/eqXS8wWpFSIZiGk7ZLJYjyS29+NUIQue/UZU4ygbmZfMe5tDDshRxA0gVg7RVBVF5hcyaanSDZ5OIVPXC+NdbpNKOKcFCJJp47ZZvqBcYoKNCEmvS6gt8j22MqbFCE5Kgb1fe9b/vqSikDDoWygQdXhopX6jPKBGbLCNltnGwhs8xFeoU1INDAKOTqbC7hoT90QZwzIQMCxPIkQ=,iv:Fz2uYJnE2Y5cBzqDuKfAKRiHS7grN9QMEI0ZJdBO/2c=,tag:p+gBcWuOpNy0/IsUmRpEuQ==,type:str] certificate-key-bazarr-tammena-me: ENC[AES256_GCM,data:H8dL0YydAMx+Azd0xpQ80ASkEFTlMlm0tIntMMbdMImJRet5/81Wfhu+hFyRKJpoYadyKqrNq2SeWEURUU2g7UtsjB6G8nCBeszdaeHe/7pdgkCe7LBW5tQWKtnYKkS3vn3Vz27i+6+NO+U+RhR7w2YaZZBwsTBy3976xGvQVjQ0Yn36kkoOvDpVEmdJyXexzgNZMnR/avFk2klwbf/LBPFme9RFylp/c02QvOgK8au3nWueYjDsKbvOobABrw8oqp5LF2i0R1vz4WTvK4LhNag6JMW/fdal9dB9QpmpC3CphVo0bJThlDbooc7qo+PiT2I1tNXCuPrNWGRyZ7WZ6iKcqKma8o+CzvRZoUuB80PjkNK6dvWF/i+CJRnQIZtHIe6xqGhHleRSo9AmRg8=,iv:DMPOGFijuiIEC9QBlb1DJynjq50H1rwpUUqDwaGSgQ8=,tag:vYFrzTvvCsYW1blobzNcbA==,type:str] +certificate-key-prowlarr-tammena-me: ENC[AES256_GCM,data:AeiJMufnFh3EDjKnkPz5S+ScxW8U9AdlLo4q8jN1r3CdVF+mp7TrYsDK//QJiTzyJkzQN4TVNj27ioUt0IQtHrlLbI83wbgZeeMtYSKxXt8PnrSnQOhZYQstXhqcyax6z2uJf0xkecSFtrUW8ZngM9PBr8T2BzcXv8TXR/tBP3qB8np+cyn8JvKbuVR9HZQO5HulXm2ZxCe0C4o+TANntZhvbJBbgihAOSukToNewPhzml7h2bLG5iit9LisdWOxihuqall5R2kE2HBax9nbK9Q1xI8y0A8jRxB0NMNyCMYUQ0eEgLCorNgalX1u9dE5QEPGbdLj3Bs2YfqHqnX6FZNDz/YWkSbEV6KIfqXFESMr5M59h1zhYZRc8f9mmHWitR0FZtkqZT62fb1fCW8=,iv:Cr2nI1qZWqSCkzDaeAwvaot11pOz6VYR+j07LJEMr7E=,tag:7hI+giA6nNbBNZ2QS9yBOg==,type:str] sops: kms: [] gcp_kms: [] @@ -38,8 +39,8 @@ sops: ZzFxdmlXaTRCY2tUZndBSDlNeUVROVUKH1CxbcdwHR3ELn9YlGvO6YbGGg++wGZv 97ez/ErXEOq/6IF6HzV3I9BsVV4WCJI2VTP8Lbiwt59qg5riH7CGJQ== -----END AGE ENCRYPTED FILE----- - lastmodified: "2024-02-15T15:11:46Z" - mac: ENC[AES256_GCM,data:m8gEI+aKC0PrBQd5M8s0Gt3klSEsqh9mdx3g5BlKep/y24xIvn9orwe7N2yUtBYiVmowNd2MfsmjXZgju8Nf7w3cnwOWbqWu28xUrYnuwJFv0R005BVLAIxJcwT/9ct6sXhzX3UTtlKsTiObkHl0ot1J8TI+XKq0x7ypPKBTjU0=,iv:iBkjfrXjuJyp8xA5Jmbdh7cPo/zdVM9WHFgOpCvQZtQ=,tag:l4TtzbA+/cml/J67kGZ5oA==,type:str] + lastmodified: "2024-02-16T12:47:47Z" + mac: ENC[AES256_GCM,data:HU2yxjvOnEA2Smgpx/vmnxLDZphBcb5HJQVHBMdPJw3fc/Bw9zYaCHiZiCI0WXYZhzRm+83JEb5i9obPa8BGk91ShnDZGlFd/WDTHztZu5sRJBlz2f7P4OagSwf4qfGop1MeZIFIdyCiZ7Btjg3HE0SauvCrgfr4/kPyn0U30xc=,iv:HVAkXozKljqLlm5oN4UfiHmDkLu0E8DRjFxsdenBTD4=,tag:OQJ+k1RoTCXfng4kWcaIrQ==,type:str] pgp: - created_at: "2023-11-06T16:58:30Z" enc: | diff --git a/secrets/pub/prowlarr-tammena-me.crt b/secrets/pub/prowlarr-tammena-me.crt new file mode 100644 index 0000000..8115365 --- /dev/null +++ b/secrets/pub/prowlarr-tammena-me.crt @@ -0,0 +1,12 @@ +-----BEGIN CERTIFICATE----- +MIIBvTCCAWOgAwIBAgIUKd83TdkOrNBfxtpOMXYy0nuMaAUwCgYIKoZIzj0EAwIw +FTETMBEGA1UEAwwKTXkgSG9tZSBDQTAeFw0yNDAyMTYxMjQ3NDZaFw0yNTAyMTUx +MjQ3NDZaMBExDzANBgNVBAMMBiouaG9tZTBZMBMGByqGSM49AgEGCCqGSM49AwEH +A0IABKmXQiFcv3K5wCCO/5qPSjoejtyAZNc3nfT5nWaBLzBs7yRslS87vTg1Kgcb +/kKZEhGa4XGMjudCgJfwa1raVQOjgZQwgZEwCwYDVR0PBAQDAgXgMBMGA1UdJQQM +MAoGCCsGAQUFBwMBMC0GA1UdEQQmMCSCE3Byb3dsYXJyLnRhbW1lbmEubWWCDXBy +b3dsYXJyLmhvbWUwHQYDVR0OBBYEFA9IGj8QZaAodwzOJai42ftSG13iMB8GA1Ud +IwQYMBaAFAD63A/bJrL4LdckOxmyIq1lmU+rMAoGCCqGSM49BAMCA0gAMEUCIHzr +cv4ra3Sh6vCWne4NOm/obCPLatAvr9RLCpemSTecAiEArk2zDII+AZmY+NZbr1i5 +7QWZI1BGBW9P+aKjO1arUSM= +-----END CERTIFICATE-----