forked from mirrors/nixpkgs
slock: needs the ability to be install with suid privileges
This commit is contained in:
parent
163668f6c4
commit
7138b55918
|
@ -89,6 +89,7 @@
|
|||
./programs/nano.nix
|
||||
./programs/oblogout.nix
|
||||
./programs/screen.nix
|
||||
./programs/slock.nix
|
||||
./programs/shadow.nix
|
||||
./programs/shell.nix
|
||||
./programs/spacefm.nix
|
||||
|
|
26
nixos/modules/programs/slock.nix
Normal file
26
nixos/modules/programs/slock.nix
Normal file
|
@ -0,0 +1,26 @@
|
|||
{ config, lib, pkgs, ... }:
|
||||
|
||||
with lib;
|
||||
|
||||
let
|
||||
cfg = config.programs.slock;
|
||||
|
||||
in
|
||||
{
|
||||
options = {
|
||||
programs.slock = {
|
||||
enable = mkOption {
|
||||
default = false;
|
||||
type = types.bool;
|
||||
description = ''
|
||||
Whether to install slock screen locker with setuid wrapper.
|
||||
'';
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
environment.systemPackages = [ pkgs.slock ];
|
||||
security.wrappers.slock.source = "${pkgs.slock.out}/bin/slock";
|
||||
};
|
||||
}
|
Loading…
Reference in a new issue