mirror of
https://github.com/aviallon/nixos-lib.git
synced 2026-04-05 17:27:50 +00:00
[Services + General] Improve GPG support (especially over SSH)
Also add SmartCard support
This commit is contained in:
parent
c64f9cb86f
commit
42bbfa7979
2 changed files with 12 additions and 0 deletions
|
|
@ -93,6 +93,13 @@ in
|
||||||
documentation.man.generateCaches = true;
|
documentation.man.generateCaches = true;
|
||||||
|
|
||||||
|
|
||||||
|
environment.shellInit = concatStringsSep "\n" [
|
||||||
|
''export GPG_TTY="$(tty)"''
|
||||||
|
''gpg-connect-agent /bye''
|
||||||
|
''export SSH_AUTH_SOCK="/run/user/$UID/gnupg/S.gpg-agent.ssh"''
|
||||||
|
];
|
||||||
|
|
||||||
|
|
||||||
nixpkgs.localSystem.system = builtins.currentSystem;
|
nixpkgs.localSystem.system = builtins.currentSystem;
|
||||||
nixpkgs.localSystem.platform = lib.systems.platforms.pc // {
|
nixpkgs.localSystem.platform = lib.systems.platforms.pc // {
|
||||||
gcc.arch = cfg.cpuArch;
|
gcc.arch = cfg.cpuArch;
|
||||||
|
|
|
||||||
|
|
@ -173,10 +173,15 @@ in {
|
||||||
programs.gnupg = {
|
programs.gnupg = {
|
||||||
agent.enable = true;
|
agent.enable = true;
|
||||||
dirmngr.enable = true;
|
dirmngr.enable = true;
|
||||||
|
agent.pinentryFlavor = "curses";
|
||||||
agent.enableSSHSupport = true;
|
agent.enableSSHSupport = true;
|
||||||
agent.enableExtraSocket = true;
|
agent.enableExtraSocket = true;
|
||||||
agent.enableBrowserSocket = true;
|
agent.enableBrowserSocket = true;
|
||||||
};
|
};
|
||||||
|
programs.ssh.startAgent = false;
|
||||||
|
|
||||||
|
# SmartCards
|
||||||
|
services.pcscd.enable = true;
|
||||||
|
|
||||||
services.avahi.enable = true; # .lan/.local resolution
|
services.avahi.enable = true; # .lan/.local resolution
|
||||||
services.avahi.nssmdns = true; # .lan/.local resolution
|
services.avahi.nssmdns = true; # .lan/.local resolution
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue