feat: conditionally toggle authentication options

This commit is contained in:
Ahwx 2024-12-13 00:45:32 +01:00
parent 4dedd8095d
commit 25fa5b5d99

View file

@ -1,4 +1,4 @@
{ pkgs, ...}: { pkgs, inputs, config, username, host, ...}:
{ {
services.udev.packages = [ pkgs.yubikey-personalization ]; services.udev.packages = [ pkgs.yubikey-personalization ];
@ -16,14 +16,14 @@
greetd.u2fAuth = true; greetd.u2fAuth = true;
sudo.u2fAuth = true; sudo.u2fAuth = true;
hyprlock.u2fAuth = true; hyprlock.u2fAuth = true;
swaylock.fprintAuth = true;
hyprlock.fprintAuth = true;
# pam.services.swaylock = {}; # Already enabled # pam.services.swaylock = {}; # Already enabled
}; };
}; };
services = { services = {
fprintd.enable = true; fprintd.enable = if (host == "sakura") then true else false;
swaylock.fprintAuth = if (host == "sakura") then true else false;
hyprlock.fprintAuth = if (host == "sakura") then true else false;
}; };
environment.systemPackages = with pkgs; [ environment.systemPackages = with pkgs; [