aboutsummaryrefslogtreecommitdiff
path: root/modules/services
diff options
context:
space:
mode:
authorWael M. Nasreddine <wael@keeptruckin.com>2020-04-15 16:06:47 -0700
committerRobert Helgesson <robert@rycee.net>2020-04-24 22:25:54 +0200
commitad8b644de19aca8a7534c9695a7446b258156d06 (patch)
tree55fd7b3d04c110dd0b5d12a5d9777bb72c407096 /modules/services
parent95b95b14075aca3eea5a747aad2e24606f2f0fea (diff)
lorri: allow customization of the lorri package
PR #1158
Diffstat (limited to 'modules/services')
-rw-r--r--modules/services/lorri.nix15
1 files changed, 12 insertions, 3 deletions
diff --git a/modules/services/lorri.nix b/modules/services/lorri.nix
index 3b2c244e3c0..a200ea6c421 100644
--- a/modules/services/lorri.nix
+++ b/modules/services/lorri.nix
@@ -9,10 +9,19 @@ let
in {
meta.maintainers = [ maintainers.gerschtli ];
- options = { services.lorri.enable = mkEnableOption "lorri build daemon"; };
+ options.services.lorri = {
+ enable = mkEnableOption "lorri build daemon";
+
+ package = mkOption {
+ type = types.package;
+ default = pkgs.lorri;
+ defaultText = literalExample "pkgs.lorri";
+ description = "Which lorri package to install.";
+ };
+ };
config = mkIf cfg.enable {
- home.packages = [ pkgs.lorri ];
+ home.packages = [ cfg.package ];
systemd.user = {
services.lorri = {
@@ -24,7 +33,7 @@ in {
};
Service = {
- ExecStart = "${pkgs.lorri}/bin/lorri daemon";
+ ExecStart = "${cfg.package}/bin/lorri daemon";
PrivateTmp = true;
ProtectSystem = "strict";
ProtectHome = "read-only";