mirror of
https://github.com/Stunkymonkey/nixos.git
synced 2025-05-24 09:54:40 +02:00
hardware/yubikey: init from nitrokey
This commit is contained in:
parent
ae77e8c649
commit
29b0fb499c
4 changed files with 26 additions and 22 deletions
|
@ -22,8 +22,8 @@ in
|
|||
};
|
||||
graphics.cpuFlavor = cpuFlavor;
|
||||
keychron.enable = true;
|
||||
nitrokey.enable = true;
|
||||
sound.enable = true;
|
||||
thunderbolt.enable = true;
|
||||
yubikey.enable = true;
|
||||
};
|
||||
}
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
./firmware
|
||||
./graphics
|
||||
./keychron
|
||||
./nitrokey
|
||||
./yubikey
|
||||
./sound
|
||||
./thunderbolt
|
||||
];
|
||||
|
|
|
@ -1,20 +0,0 @@
|
|||
{ config, lib, pkgs, ... }:
|
||||
let
|
||||
cfg = config.my.hardware.nitrokey;
|
||||
in
|
||||
{
|
||||
options.my.hardware.nitrokey = {
|
||||
enable = lib.mkEnableOption "nitrokey configuration";
|
||||
};
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
services.udev.packages = [ pkgs.nitrokey-udev-rules ];
|
||||
programs = {
|
||||
ssh.startAgent = false;
|
||||
gnupg.agent = {
|
||||
enable = true;
|
||||
enableSSHSupport = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
24
modules/hardware/yubikey/default.nix
Normal file
24
modules/hardware/yubikey/default.nix
Normal file
|
@ -0,0 +1,24 @@
|
|||
{ config, lib, pkgs, ... }:
|
||||
let
|
||||
cfg = config.my.hardware.yubikey;
|
||||
in
|
||||
{
|
||||
options.my.hardware.yubikey = {
|
||||
enable = lib.mkEnableOption "yubikey configuration";
|
||||
};
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
services.udev.packages = [ pkgs.yubikey-personalization ];
|
||||
programs = {
|
||||
ssh.startAgent = false;
|
||||
gnupg.agent = {
|
||||
enable = true;
|
||||
enableSSHSupport = true;
|
||||
};
|
||||
};
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
yubikey-manager
|
||||
];
|
||||
};
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue