sisyphus/nixos/modules/hardware/yubikey/default.nix

20 lines
420 B
Nix
Raw Normal View History

2024-03-22 21:16:12 +01:00
{ config, lib, pkgs, ... }:
let
cfg = config.sisyphus.hardware.yubikey;
in {
options.sisyphus.hardware.yubikey.enable = lib.mkEnableOption "YubiKey support";
config = lib.mkIf cfg.enable {
programs.gnupg.agent = {
enable = true;
2024-03-30 23:05:05 +01:00
# TODO Necessary?
# enableSSHSupport = true;
# pinentryFlavor = "curses";
2024-03-22 21:16:12 +01:00
};
2024-03-30 23:05:05 +01:00
# Enable smart card reading
services.pcscd.enable = true;
2024-03-22 21:16:12 +01:00
};
}