dovecot: update fts_xapian
authorJulien Moutinho <julm@sourcephile.fr>
Sun, 29 Mar 2020 03:01:07 +0000 (05:01 +0200)
committerJulien Moutinho <julm@sourcephile.fr>
Sun, 29 Mar 2020 03:01:07 +0000 (05:01 +0200)
servers/mermet/dovecot.nix
shell.nix

index 533dc4f27f93fa2d0fede66398f7d7395dfd86b3..54c9488246d460ec386574780e28c110a3adacff 100644 (file)
@@ -228,6 +228,9 @@ services.dovecot2 = {
 
     mail_plugins = $mail_plugins fts fts_xapian
     plugin {
+      # WARNING: doveadm fts rescan is buggy, it will delete the index:
+      # https://dovecot.org/pipermail/dovecot/2019-February/114709.html
+      # If need be, use rather: doveadm index -u "*@sourcephile.fr" -q '*'
       plugin = fts fts_xapian
       fts = xapian
       fts_autoindex = yes
@@ -237,7 +240,9 @@ services.dovecot2 = {
       # 2 and 20 are the NGram values for header fields, which means the
       # keywords created for fields (To, Cc, ...) are between is 2 and 20 chars long.
       # Full words are also added by default.
-      fts_xapian = partial=2 full=20 verbose=0
+      fts_xapian = partial=2 full=20 attachments=1 verbose=0
+      fts_languages = en fr
+      #fts_dovecot_fs = posix:prefix=%h/fts/
     }
 
     mail_plugins = $mail_plugins quota
index cb3e88dbd5e762e0aa6fcb682d3ebd59e4b7de70..7219f2f974e83d9a1f581dae67b3a8cee71b35aa 100644 (file)
--- a/shell.nix
+++ b/shell.nix
@@ -18,7 +18,7 @@ let
     */
     { meta.description = "Dovecot plugin for Full Text Search (FTS) with Xapian";
       url = "https://github.com/NixOS/nixpkgs/pull/78780.diff";
-      sha256 = "053md69ryybj27cp0xdfrza48zyzpblk6wvb2m2dbs9hm0gmcwc4";
+      sha256 = "15ix8kwisjcgf4n7x7vlh223rb3206lcd5b13wbcvld07rzinjkc";
     }
     /* Disabled because it triggers the local build of too many reverse-dependencies
     { meta.description = "openldap: enable sha2 and pbkdf2 modules";