nix-config/modules/utils/auth.nix

43 lines
1 KiB
Nix

{ pkgs, lib, ... }:
{
services.fprintd.enable = true;
security.pam.services = {
login.fprintAuth = lib.mkDefault true;
sudo.fprintAuth = true;
greetd.enableGnomeKeyring = true;
};
services.greetd = {
enable = true;
settings = {
default_session = {
command = "${pkgs.tuigreet}/bin/tuigreet -t -g \"Hello there (^^)/\" --cmd 'Hyprland'";
user = "etwas";
};
};
};
security.polkit.enable = true;
systemd = {
user.services.polkit-gnome-authentication-agent-1 = {
description = "polkit-gnome-authentication-agent-1";
wantedBy = [ "graphical-session.target" ];
wants = [ "graphical-session.target" ];
serviceConfig = {
Type = "simple";
ExecStart = "${pkgs.polkit_gnome}/libexec/polkit-gnome-authentication-agent-1";
Restart = "on-failure";
RestartSec = 1;
TimeoutStopSec = 10;
};
};
};
programs.gnupg.agent = {
enable = true;
enableSSHSupport = true;
pinentryPackage = pkgs.pinentry-gnome3;
};
}