[Services + General] Improve GPG support (especially over SSH)

Also add SmartCard support
This commit is contained in:
Antoine Viallon 2022-03-21 00:04:33 +01:00
parent c64f9cb86f
commit 42bbfa7979
Signed by: aviallon
GPG key ID: 186FC35EDEB25716
2 changed files with 12 additions and 0 deletions

View file

@ -93,6 +93,13 @@ in
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.platform = lib.systems.platforms.pc // {
gcc.arch = cfg.cpuArch;