nixos/lidarr: allow specifying package

This commit allows users of `services.lidarr` to specify the package
that is used with `services.lidarr.package`.
This commit is contained in:
David Wood 2019-06-24 09:53:38 +01:00
parent 2307ac9fe2
commit 7e38a64709
No known key found for this signature in database
GPG Key ID: 2592E76C87381FD9

View File

@ -9,6 +9,13 @@ in
options = { options = {
services.lidarr = { services.lidarr = {
enable = mkEnableOption "Lidarr"; enable = mkEnableOption "Lidarr";
package = mkOption {
type = types.package;
default = pkgs.lidarr;
defaultText = "pkgs.lidarr";
description = "The Lidarr package to use";
};
}; };
}; };
@ -22,7 +29,7 @@ in
Type = "simple"; Type = "simple";
User = "lidarr"; User = "lidarr";
Group = "lidarr"; Group = "lidarr";
ExecStart = "${pkgs.lidarr}/bin/Lidarr"; ExecStart = "${cfg.package}/bin/Lidarr";
Restart = "on-failure"; Restart = "on-failure";
StateDirectory = "lidarr"; StateDirectory = "lidarr";