Fix swayidle

This commit is contained in:
Andrea Ciceri 2023-12-11 22:01:51 +01:00
parent 3c29cd62f7
commit 55835d1367
Signed by: aciceri
SSH key fingerprint: SHA256:/AagBweyV4Hlfg9u092n8hbHwD5fcB6A3qhDiDA65Rg
4 changed files with 23 additions and 14 deletions

View file

@ -6,17 +6,17 @@
services.swayidle = let services.swayidle = let
# Downgraded due to # Downgraded due to
# https://github.com/mortie/swaylock-effects/issues/95 # https://github.com/mortie/swaylock-effects/issues/95
swaylock-effects = pkgs.swaylock-effects.overrideAttrs (_: { # swaylock-effects = pkgs.swaylock-effects.overrideAttrs (_: {
version = "jirutka-master"; # version = "jirutka-master";
src = pkgs.fetchFromGitHub { # src = pkgs.fetchFromGitHub {
owner = "jirutka"; # owner = "jirutka";
repo = "swaylock-effects"; # repo = "swaylock-effects";
rev = "7c5681ce96587ce3090c6698501faeccdfdc157d"; # rev = "7c5681ce96587ce3090c6698501faeccdfdc157d";
sha256 = "sha256-09Kq90wIIF9lPjiY2anf9MSgi/EqeXKXW1mFmhxA/aM"; # sha256 = "sha256-09Kq90wIIF9lPjiY2anf9MSgi/EqeXKXW1mFmhxA/aM";
}; # };
}); # });
swaylockWithArgs = pkgs.writeScriptBin "swaylockWithArgs" '' swaylockWithArgs = pkgs.writeScriptBin "swaylockWithArgs" ''
${swaylock-effects}/bin/swaylock \ ${pkgs.swaylock-effects}/bin/swaylock \
--daemonize \ --daemonize \
--screenshots \ --screenshots \
--clock \ --clock \

View file

@ -26,6 +26,7 @@
"ssh-initrd" "ssh-initrd"
"hercules-ci" "hercules-ci"
"printing" "printing"
"pam"
] ]
++ [ ++ [
./disko.nix ./disko.nix

View file

@ -1,13 +1,15 @@
{ {
imports = [../pam];
services.fprintd = { services.fprintd = {
enable = false; # temporarily disable enable = false; # temporarily disable
}; };
security.polkit.enable = true; # TODO needed? security.polkit.enable = true; # TODO needed?
security.pam.services.swaylock.text = '' # security.pam.services.swaylock.text = ''
auth include login # auth include login
auth sufficient pam_unix.so try_first_pass likeauth nullok # auth sufficient pam_unix.so try_first_pass likeauth nullok
''; # '';
# # auth sufficient pam_fprintd.so # # auth sufficient pam_fprintd.so
} }

6
modules/pam/default.nix Normal file
View file

@ -0,0 +1,6 @@
{
security.pam.services.swaylock.text = ''
auth include login
auth sufficient pam_unix.so try_first_pass likeauth nullok
'';
}