From 7af587d54655fdc52e312ab790439d0a2b390473 Mon Sep 17 00:00:00 2001 From: wi11-holdsworth <83637728+wi11-holdsworth@users.noreply.github.com> Date: Mon, 29 Dec 2025 16:37:00 +1100 Subject: [PATCH] feat: install readarr --- modules/nixos/bundles/server.nix | 2 +- modules/nixos/features/homepage-dashboard.nix | 160 ++++++++++-------- modules/nixos/features/readarr.nix | 33 ++++ secrets/readarr.age | 10 ++ secrets/secrets.nix | 1 + 5 files changed, 131 insertions(+), 75 deletions(-) create mode 100644 modules/nixos/features/readarr.nix create mode 100644 secrets/readarr.age diff --git a/modules/nixos/bundles/server.nix b/modules/nixos/bundles/server.nix index c4ea292..210735e 100644 --- a/modules/nixos/bundles/server.nix +++ b/modules/nixos/bundles/server.nix @@ -14,7 +14,6 @@ "karakeep" "lidarr" "miniflux" - "radicale" "nginx" "ntfy-sh" "paperless" @@ -22,6 +21,7 @@ "qbittorrent" "radarr" "radicale" + "readarr" "sonarr" "syncthing" "vaultwarden" diff --git a/modules/nixos/features/homepage-dashboard.nix b/modules/nixos/features/homepage-dashboard.nix index b4b7897..42a4f2a 100644 --- a/modules/nixos/features/homepage-dashboard.nix +++ b/modules/nixos/features/homepage-dashboard.nix @@ -30,6 +30,7 @@ let "paperless" "prowlarr" "radarr" + "readarr" "sonarr" # keep-sorted end ]; @@ -41,74 +42,8 @@ in listenPort = port; allowedHosts = "homepage-dashboard.fi33.buzz"; services = [ - # keep-sorted start block=yes { "Media Management" = [ - { - "Immich" = { - "description" = "Photo backup"; - "icon" = "immich.svg"; - "href" = "https://immich.fi33.buzz/"; - "widget" = { - "type" = "immich"; - "fields" = [ - "users" - "photos" - "videos" - "storage" - ]; - "url" = "https://immich.fi33.buzz/"; - "version" = 2; - "key" = "@immich@"; - }; - }; - } - { - "Miniflux" = { - "description" = "RSS aggregator"; - "icon" = "miniflux.svg"; - "href" = "https://miniflux.fi33.buzz/"; - "widget" = { - "type" = "miniflux"; - "url" = "https://miniflux.fi33.buzz/"; - "key" = "@miniflux@"; - }; - }; - } - { - "Paperless" = { - "description" = "Digital filing cabinet"; - "icon" = "paperless.svg"; - "href" = "https://paperless.fi33.buzz/"; - "widget" = { - "type" = "paperlessngx"; - "url" = "https://paperless.fi33.buzz/"; - "username" = "admin"; - "password" = "@paperless@"; - }; - }; - } - ]; - } - { - "Media Streaming" = [ - { - "Jellyfin" = { - "description" = "Media streaming"; - "icon" = "jellyfin.svg"; - "href" = "https://jellyfin.fi33.buzz/"; - "widget" = { - "type" = "jellyfin"; - "url" = "https://jellyfin.fi33.buzz/"; - "key" = "@jellyfin@"; - "enableBlocks" = true; - "enableNowPlaying" = true; - "enableUser" = true; - "showEpisodeNumber" = true; - "expandOneStreamToTwoRows" = false; - }; - }; - } { "Radarr" = { "description" = "Movie collection manager"; @@ -148,6 +83,19 @@ in }; }; } + { + "Readarr" = { + "description" = "Book collection manager"; + "icon" = "readarr.svg"; + "href" = "https://readarr.fi33.buzz/"; + "widget" = { + "type" = "readarr"; + "url" = "https://readarr.fi33.buzz/"; + "key" = "@readarr@"; + "enableQueue" = true; + }; + }; + } { "Prowlarr" = { "description" = "Indexer management tool"; @@ -169,6 +117,71 @@ in } ]; } + { + "Media Streaming" = [ + { + "Immich" = { + "description" = "Photo backup"; + "icon" = "immich.svg"; + "href" = "https://immich.fi33.buzz/"; + "widget" = { + "type" = "immich"; + "fields" = [ + "users" + "photos" + "videos" + "storage" + ]; + "url" = "https://immich.fi33.buzz/"; + "version" = 2; + "key" = "@immich@"; + }; + }; + } + { + "Jellyfin" = { + "description" = "Media streaming"; + "icon" = "jellyfin.svg"; + "href" = "https://jellyfin.fi33.buzz/"; + "widget" = { + "type" = "jellyfin"; + "url" = "https://jellyfin.fi33.buzz/"; + "key" = "@jellyfin@"; + "enableBlocks" = true; + "enableNowPlaying" = true; + "enableUser" = true; + "showEpisodeNumber" = true; + "expandOneStreamToTwoRows" = false; + }; + }; + } + { + "Miniflux" = { + "description" = "RSS aggregator"; + "icon" = "miniflux.svg"; + "href" = "https://miniflux.fi33.buzz/"; + "widget" = { + "type" = "miniflux"; + "url" = "https://miniflux.fi33.buzz/"; + "key" = "@miniflux@"; + }; + }; + } + { + "Paperless" = { + "description" = "Digital filing cabinet"; + "icon" = "paperless.svg"; + "href" = "https://paperless.fi33.buzz/"; + "widget" = { + "type" = "paperlessngx"; + "url" = "https://paperless.fi33.buzz/"; + "username" = "admin"; + "password" = "@paperless@"; + }; + }; + } + ]; + } { "Services" = [ { @@ -226,7 +239,6 @@ in } ]; } - # keep-sorted end ]; settings = { title = "Mission Control"; @@ -234,13 +246,6 @@ in color = "neutral"; headerStyle = "clean"; layout = [ - { - "Media Management" = { - style = "row"; - columns = 3; - useEqualHeights = true; - }; - } { "Media Streaming" = { style = "row"; @@ -254,6 +259,13 @@ in columns = 3; }; } + { + "Media Management" = { + style = "row"; + columns = 3; + useEqualHeights = true; + }; + } { "Utilities" = { style = "row"; diff --git a/modules/nixos/features/readarr.nix b/modules/nixos/features/readarr.nix new file mode 100644 index 0000000..f0f3227 --- /dev/null +++ b/modules/nixos/features/readarr.nix @@ -0,0 +1,33 @@ +let + port = 5016; +in +{ + services = { + readarr = { + enable = true; + dataDir = "/srv/readarr"; + settings.server = { + inherit port; + }; + group = "media"; + }; + + # borgmatic.settings = { + # source_directories = [ ]; + # postgresql_databases = [ + # { + # name = "readarr"; + # hostname = "localhost"; + # username = "root"; + # password = "{credential systemd borgmatic-pg}"; + # } + # ]; + # }; + + nginx.virtualHosts."readarr.fi33.buzz" = { + forceSSL = true; + useACMEHost = "fi33.buzz"; + locations."/".proxyPass = "http://localhost:${toString port}"; + }; + }; +} diff --git a/secrets/readarr.age b/secrets/readarr.age new file mode 100644 index 0000000..e0d0607 --- /dev/null +++ b/secrets/readarr.age @@ -0,0 +1,10 @@ +age-encryption.org/v1 +-> ssh-ed25519 qLT+DQ qeJ25W5TGvWY8xc1I5sjjtP/98nGqoRMIFk6xLIbmi8 +RhUcEjz6mFp6uNVOpOgg6fPyL2cyrZH1ZWJTrax2xOE +-> ssh-ed25519 7+xRyQ jhJX/0+ZO+teoM2rUmdyFuI9V+tMe5kQaaHQFxwBGSU +fJmXSc/c3lth0cQgx8p/7G0WrnfgioSs8OcRa56B2s0 +-> ssh-ed25519 LtK9yQ UH9T6lRLG0pi0P84B9Zs/22nCKAoOAwL6KAmj+536U4 +h2DEqoPLgFqmVZOk/RhAIuifCexqt3ZFsIsCDm5KI3M +--- 6FY4tnGR8EIQyCWc3Xa3t8EqwcynoORmZqsp9zWUzZM +nā]Z0rTi:EE!  +uB{4cfvޟKj^2/` \ No newline at end of file diff --git a/secrets/secrets.nix b/secrets/secrets.nix index 69b1be1..74ef3d4 100644 --- a/secrets/secrets.nix +++ b/secrets/secrets.nix @@ -30,6 +30,7 @@ in "prowlarr.age".publicKeys = users; "radarr.age".publicKeys = users; "radicale.age".publicKeys = users; + "readarr.age".publicKeys = users; "sonarr.age".publicKeys = users; "vaultwarden-admin.age".publicKeys = users; # keep-sorted end -- 2.53.0