aboutsummaryrefslogtreecommitdiff
path: root/nix/modules/home/mbsync.nix
diff options
context:
space:
mode:
Diffstat (limited to 'nix/modules/home/mbsync.nix')
-rw-r--r--nix/modules/home/mbsync.nix31
1 files changed, 31 insertions, 0 deletions
diff --git a/nix/modules/home/mbsync.nix b/nix/modules/home/mbsync.nix
new file mode 100644
index 0000000..e509c27
--- /dev/null
+++ b/nix/modules/home/mbsync.nix
@@ -0,0 +1,31 @@
+{ lib, config, ... }:
+{
+ enable = lib.mkDefault config.profiles.home.email.enable;
+ extraConfig = ''
+ IMAPAccount ret2pop
+ Host ${config.profiles.home.email.imapsServer}
+ User ${config.profiles.email.email}
+ PassCmd "cat ${config.sops.secrets.mail.path}"
+ Port 993
+ TLSType IMAPS
+ AuthMechs *
+ CertificateFile /etc/ssl/certs/ca-certificates.crt
+
+ IMAPStore ret2pop-remote
+ Account ret2pop
+
+ MaildirStore ret2pop-local
+ Path ~/email/ret2pop/
+ Inbox ~/email/ret2pop/INBOX
+ SubFolders Verbatim
+
+ Channel ret2pop
+ Far :ret2pop-remote:
+ Near :ret2pop-local:
+ Patterns *
+ Create Near
+ Sync All
+ Expunge None
+ SyncState *
+ '';
+}