about summary refs log tree commit diff
path: root/home/profiles/communication/default.nix
diff options
context:
space:
mode:
authorsefidel <contact@sefidel.net>2023-02-21 16:10:58 +0900
committersefidel <contact@sefidel.net>2023-02-21 16:10:58 +0900
commit4f3edea6903f3e9ca46176c06305147e71e12125 (patch)
tree0d1379aa40174499fb08320663f7221aa143f2f4 /home/profiles/communication/default.nix
parenta92c4a2c9021b24f3959b57d25fb4a814991d120 (diff)
downloadnixrc-4f3edea6903f3e9ca46176c06305147e71e12125.tar.gz
nixrc-4f3edea6903f3e9ca46176c06305147e71e12125.zip
feat: use passage for IMAP authentication
Diffstat (limited to 'home/profiles/communication/default.nix')
-rw-r--r--home/profiles/communication/default.nix6
1 files changed, 2 insertions, 4 deletions
diff --git a/home/profiles/communication/default.nix b/home/profiles/communication/default.nix
index 86028e8..643b511 100644
--- a/home/profiles/communication/default.nix
+++ b/home/profiles/communication/default.nix
@@ -24,9 +24,6 @@ in
 
   config = lib.mkIf cfg.enable (lib.mkMerge [
     (lib.mkIf pkgs.stdenv.isLinux { # TODO: is this needed?
-
-      sops.secrets.sef-imap-password = { };
-
       accounts.email = {
         maildirBasePath = "${config.home.homeDirectory}/mail";
 
@@ -76,7 +73,7 @@ in
           primary = true;
           realName = "***REMOVED***";
           userName = poorObfuscation "sefidel.com" "contact";
-          passwordCommand = "${pkgs.coreutils}/bin/cat ${builtins.replaceStrings ["%r"] ["$XDG_RUNTIME_DIR"] config.sops.secrets.sef-imap-password.path}";
+          passwordCommand = "${pkgs.passage}/bin/passage show email/sef";
         };
       };
 
@@ -271,6 +268,7 @@ in
           Type = "oneshot";
           ExecStart = "${mbsyncCmd} --all";
           RemainAfterExit = true;
+          TimeoutStartSec = "5min";
         };
         Install.WantedBy = [ "default.target" ];
       };