44 lines
798 B
Nix
44 lines
798 B
Nix
# manages and downloads films
|
|
{
|
|
config,
|
|
lib,
|
|
pkgs,
|
|
...
|
|
}:
|
|
let
|
|
cfg = config.my.profiles.radarr;
|
|
hostName = config.networking.hostName;
|
|
port = 7878;
|
|
in
|
|
# domain = config.networking.domain;
|
|
# port = 7878;
|
|
{
|
|
options.my.profiles.radarr = with lib; {
|
|
enable = mkEnableOption "Sonarr for films management";
|
|
|
|
};
|
|
|
|
config = lib.mkIf cfg.enable {
|
|
services.radarr = {
|
|
enable = true;
|
|
openFirewall = true;
|
|
};
|
|
|
|
my.homepage.services = [
|
|
{
|
|
group = "Media";
|
|
name = "Radarr";
|
|
description = "Movie management";
|
|
href = "http://${hostName}:${toString port}";
|
|
icon = "radarr.png";
|
|
}
|
|
];
|
|
|
|
my.profiles.prowlarr.enable = true;
|
|
|
|
systemd.services.radarr = {
|
|
after = [ "network-online.target" ];
|
|
};
|
|
};
|
|
}
|