diff options
author | Ben Sima <ben@bsima.me> | 2021-04-16 14:19:19 -0400 |
---|---|---|
committer | Ben Sima <ben@bsima.me> | 2021-04-18 15:17:10 -0400 |
commit | bfb347fecfde85ef08b74c9e9d57e99cd504beea (patch) | |
tree | 18376638b0e6e9589312d8b3afedbcc16f847deb | |
parent | 2369e861da3c925c1b90d0d3d3318351e4187e44 (diff) |
gpg refresh timer
-rw-r--r-- | linux.nix | 14 |
1 files changed, 13 insertions, 1 deletions
@@ -356,7 +356,7 @@ in gpg-agent = { enable = true; - enableScDaemon = true; + enableScDaemon = true; # smart card support defaultCacheTtl = 1800; # 30 minutes maxCacheTtl = 7200; # 2 hours enableSshSupport = false; @@ -412,4 +412,16 @@ in enable = true; }; }; + + systemd.user = { + services = { + "gpg-refresh".Service.ExecStart = "${pkgs.gnupg}/bin/gpg --refresh"; + }; + timers = { + "gpg-refresh" = { + Install.WantedBy = ["timers.target"]; + Timer.OnCalendar = "daily"; + }; + }; + }; } |