29 lines
882 B
Nix
Raw Normal View History

2024-03-23 18:01:09 +03:00
{ config, pkgs, lib, ... }:
2022-02-11 14:07:03 +03:00
with config.deviceSpecific; {
2022-12-10 22:34:39 +03:00
home-manager.users.${config.mainuser} = {
2021-06-16 05:30:04 +03:00
programs.gpg = {
enable = true;
2024-02-06 23:58:12 +03:00
homedir = config.services.password-store.gnupgHome;
2021-06-16 05:30:04 +03:00
};
2021-02-07 02:38:11 +03:00
services.gpg-agent = {
enable = true;
enableSshSupport = true;
2024-03-23 18:01:09 +03:00
pinentryPackage = if !isServer then pkgs.pinentry-gnome3 else pkgs.pinentry-curses;
2021-06-16 23:42:44 +03:00
sshKeys = [
"7A7130ABF128CC2C32B3D6AD27515056B0193CE1"
2021-09-28 01:51:25 +03:00
"E6A6377C3D0827C36428A290199FDB3B91414AFE"
2021-06-16 23:42:44 +03:00
];
2021-02-07 02:38:11 +03:00
};
2022-07-02 19:30:20 +03:00
systemd.user.services.gpg-agent = {
Service = {
Environment = lib.mkForce [
"GPG_TTY=/dev/tty1"
"DISPLAY=:0"
2024-02-06 23:58:12 +03:00
"GNUPGHOME=${config.services.password-store.gnupgHome}"
2022-07-02 19:30:20 +03:00
];
};
};
2021-02-07 02:38:11 +03:00
};
2024-03-23 18:01:09 +03:00
services.dbus.packages = lib.mkIf (!isServer) [ pkgs.gcr ];
2023-01-13 04:03:15 +03:00
persist.state.homeDirectories = [ ".local/share/gnupg" ];
2021-02-07 02:38:11 +03:00
}