summaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authorsinanmohd <sinan@sinanmohd.com>2023-09-13 21:33:24 +0530
committersinanmohd <sinan@sinanmohd.com>2023-09-13 21:42:49 +0530
commit8903c9ad29bf10d14d97f3b511eb9e1376ac835b (patch)
tree0794034b25b2a82bde7db72d7d8f684dea8b5af4 /modules
parentc10a228d9bb25b0ce2d4df1c3215bd574aceeadd (diff)
modules/seatd: support for readiness notification
Diffstat (limited to 'modules')
-rw-r--r--modules/seatd.nix8
1 files changed, 5 insertions, 3 deletions
diff --git a/modules/seatd.nix b/modules/seatd.nix
index 32fff58..51977df 100644
--- a/modules/seatd.nix
+++ b/modules/seatd.nix
@@ -28,7 +28,7 @@ in
};
config = lib.mkIf cfg.enable {
- environment.systemPackages = with pkgs; [ seatd ];
+ environment.systemPackages = with pkgs; [ seatd sdnotify-wrapper ];
users.groups.seat = lib.mkIf (cfg.group == "seat") {};
systemd.services.seatd = {
@@ -39,8 +39,10 @@ in
restartIfChanged = false;
serviceConfig = {
- Type = "simple";
- ExecStart = "${pkgs.seatd.bin}/bin/seatd -u ${cfg.user} -g ${cfg.group} -l ${cfg.logLevel}";
+ Type = "notify";
+ NotifyAccess = "all";
+ SyslogIdentifier = "seatd";
+ ExecStart = "${pkgs.sdnotify-wrapper}/bin/sdnotify-wrapper ${pkgs.seatd.bin}/bin/seatd -n 1 -u ${cfg.user} -g ${cfg.group} -l ${cfg.logLevel}";
RestartSec = 1;
Restart = "always";
};