From f6e600c20d6a97ebeda23fa2bb5621646222b2b0 Mon Sep 17 00:00:00 2001 From: Gregor Kleen Date: Sat, 2 Jan 2021 20:53:17 +0100 Subject: sif: import config --- modules/kill-user.nix | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 modules/kill-user.nix (limited to 'modules/kill-user.nix') diff --git a/modules/kill-user.nix b/modules/kill-user.nix new file mode 100644 index 00000000..dd897b36 --- /dev/null +++ b/modules/kill-user.nix @@ -0,0 +1,13 @@ +{ lib, pkgs, config, ... }: +{ + options = { + systemd.kill-user.enable = lib.mkEnableOption "Systemd kill-user@ services"; + }; + + config.systemd.services."kill-user@" = lib.mkIf config.systemd.kill-user.enable { + serviceConfig = { + Type = "oneshot"; + ExecStart = "${pkgs.systemd}/bin/loginctl kill-user %I"; + }; + }; +} -- cgit v1.2.3