diff options
author | Kjetil Orbekk <kj@orbekk.com> | 2021-03-07 15:11:56 -0500 |
---|---|---|
committer | Kjetil Orbekk <kj@orbekk.com> | 2021-03-07 15:11:56 -0500 |
commit | 78529ae2641e8645ee3459753819d0ecff655d86 (patch) | |
tree | 03f2f8e25ad0decd0f6dcd0a65664a8f7a90796a /config/yubikey.nix | |
parent | 46e1d2a1552d4aaad676faf49cb0582515d62c86 (diff) |
Refactor configs into modules
Diffstat (limited to 'config/yubikey.nix')
-rw-r--r-- | config/yubikey.nix | 51 |
1 files changed, 0 insertions, 51 deletions
diff --git a/config/yubikey.nix b/config/yubikey.nix deleted file mode 100644 index d10bb57..0000000 --- a/config/yubikey.nix +++ /dev/null @@ -1,51 +0,0 @@ -{ config, lib, pkgs, ... }: -let - yubikey-pkgs = with pkgs; [ - ccid - libu2f-host - libusb - rng_tools - yubikey-manager - yubikey-personalization - gnupg - pinentry - ]; -in -{ - services.pcscd.enable = true; - services.udev.packages = with pkgs; [ - libu2f-host - yubikey-personalization - ]; - services.gnome3.gnome-keyring.enable = lib.mkForce false; - - programs.gnupg.agent = { - enable = true; - enableSSHSupport = true; - }; - # Use GPG agent instead. - programs.ssh.startAgent = lib.mkDefault false; - - environment = { - systemPackages = yubikey-pkgs; - }; - - security.sudo.extraRules = [ - { - groups = [ "wheel" ]; - commands = [ { command = "${pkgs.systemd}/bin/systemctl restart pcscd"; options = [ "NOPASSWD" ]; } ]; - } - ]; - - systemd.user.services.restart-pcscd = { - description = "Redshift colour temperature adjuster"; - wantedBy = [ "graphical-session.target" ]; - partOf = [ "graphical-session.target" ]; - serviceConfig = { - ExecStart = '' - sudo systemctl restart pcscd - ''; - Type = "oneshot"; - }; - }; -} |