nixos/jackflix: Add Jellyseerr

This commit is contained in:
Jack O'Sullivan 2023-11-13 20:49:59 +00:00
parent fe4a24ab17
commit ddc2ed2919
4 changed files with 37 additions and 3 deletions

View File

@ -4,10 +4,12 @@
uids = {
matrix-syncv3 = 400;
gitea-runner = 401;
jellyseerr = 402;
};
gids = {
matrix-syncv3 = 400;
gitea-runner = 401;
jellyseerr = 402;
};
};

View File

@ -22,7 +22,7 @@ in
configuration = { lib, pkgs, config, ... }:
let
inherit (lib);
inherit (lib) mkForce;
in
{
imports = [ ./networking.nix ];
@ -37,14 +37,22 @@ in
};
};
users = {
groups.media.gid = 2000;
users = with lib.my.c.ids; {
users = {
"${config.my.user.config.name}".extraGroups = [ "media" ];
transmission.extraGroups = [ "media" ];
radarr.extraGroups = [ "media" ];
sonarr.extraGroups = [ "media" ];
jellyseerr = {
isSystemUser = true;
uid = uids.jellyseerr;
group = "jellyseerr";
};
};
groups = {
media.gid = 2000;
jellyseerr.gid = gids.jellyseerr;
};
};
@ -55,6 +63,12 @@ in
radarr.serviceConfig.UMask = "0002";
sonarr.serviceConfig.UMask = "0002";
jellyseerr.serviceConfig = {
# Needs to be able to read its secrets
DynamicUser = mkForce false;
User = "jellyseerr";
Group = "jellyseerr";
};
# https://github.com/NixOS/nixpkgs/issues/258793#issuecomment-1748168206
transmission.serviceConfig = {
@ -96,6 +110,10 @@ in
jackett.enable = true;
radarr.enable = true;
sonarr.enable = true;
jellyseerr = {
enable = true;
openFirewall = true;
};
jellyfin.enable = true;
};

View File

@ -288,6 +288,10 @@ in
}
(ssoServer "generic")
];
"gib.${pubDomain}" = {
locations."/".proxyPass = "http://jackflix-ctr.${domain}:5055";
useACMEHost = pubDomain;
};
"jackflix.${pubDomain}" =
let

View File

@ -335,6 +335,16 @@ in
(persistSimpleSvc "jackett")
(persistSimpleSvc "radarr")
(persistSimpleSvc "sonarr")
(mkIf config.services.jellyseerr.enable {
my.tmproot.persistence.config.directories = [
{
directory = "/var/lib/jellyseerr";
mode = "0750";
user = "jellyseerr";
group = "jellyseerr";
}
];
})
(mkIf config.services.minio.enable {
my.tmproot.persistence.config.directories = [
{