about summary refs log tree commit diff
path: root/nixos
diff options
context:
space:
mode:
authorMatthias Beyer <mail@beyermatthias.de>2024-06-10 15:26:15 +0200
committerGitHub <noreply@github.com>2024-06-10 15:26:15 +0200
commit8a9a6c764e378813aba0ecab703aeda72bcc2d74 (patch)
tree31bb1d02d681cddfcca4a3b5a517eff3c871e369 /nixos
parent3369c121872617068a879fad42bf5ba25f16c645 (diff)
parent04548e7e1f256a0ff270f48d0a4dbc224aeeb728 (diff)
Merge pull request #314422 from eclairevoyant/journalwatch-fix-module
nixos/journalwatch: add package option
Diffstat (limited to 'nixos')
-rw-r--r--nixos/modules/services/logging/journalwatch.nix4
1 files changed, 3 insertions, 1 deletions
diff --git a/nixos/modules/services/logging/journalwatch.nix b/nixos/modules/services/logging/journalwatch.nix
index 71b29d57b7eb7..48fd992ffb65a 100644
--- a/nixos/modules/services/logging/journalwatch.nix
+++ b/nixos/modules/services/logging/journalwatch.nix
@@ -56,6 +56,8 @@ in {
         '';
       };
 
+      package = mkPackageOption pkgs "journalwatch" { };
+
       priority = mkOption {
         type = types.int;
         default = 6;
@@ -240,7 +242,7 @@ in {
         # requires a relative directory name to create beneath /var/lib
         StateDirectory = user;
         StateDirectoryMode = "0750";
-        ExecStart = "${pkgs.python3Packages.journalwatch}/bin/journalwatch mail";
+        ExecStart = "${getExe cfg.package} mail";
         # lowest CPU and IO priority, but both still in best-effort class to prevent starvation
         Nice=19;
         IOSchedulingPriority=7;