summary refs log tree commit diff
path: root/host/Rory-nginx/services/matrix/synapse/workers/user-dir.nix
diff options
context:
space:
mode:
authorRory& <root@rory.gay>2024-08-04 05:08:05 +0200
committerRory& <root@rory.gay>2024-08-04 05:08:05 +0200
commit4402873891edace4b678af537236ff1d81bba585 (patch)
tree343f32b070b98eaba7e11ab77bd27ce98a464bc7 /host/Rory-nginx/services/matrix/synapse/workers/user-dir.nix
parentUpdate flake lock (diff)
downloadRory-Open-Architecture-4402873891edace4b678af537236ff1d81bba585.tar.xz
Server config cleanup
Diffstat (limited to 'host/Rory-nginx/services/matrix/synapse/workers/user-dir.nix')
-rw-r--r--host/Rory-nginx/services/matrix/synapse/workers/user-dir.nix8
1 files changed, 5 insertions, 3 deletions
diff --git a/host/Rory-nginx/services/matrix/synapse/workers/user-dir.nix b/host/Rory-nginx/services/matrix/synapse/workers/user-dir.nix
index 2eabe9d..f8d118e 100644
--- a/host/Rory-nginx/services/matrix/synapse/workers/user-dir.nix
+++ b/host/Rory-nginx/services/matrix/synapse/workers/user-dir.nix
@@ -7,6 +7,8 @@
 
 let
   cfg = config.services.matrix-synapse;
+  workerName = "user_dir";
+  workerRoutes = [ "~ ^/_matrix/client/(api/v1|r0|v3|unstable)/user_directory/search$" ];
 in
 {
   config = lib.mkIf cfg.enableUserDirWorker {
@@ -18,7 +20,7 @@ in
           };
         };
 
-        update_user_directory_from_worker = "user_dir";
+        update_user_directory_from_worker = workerName;
       };
 
       workers = {
@@ -27,7 +29,7 @@ in
           worker_listeners = [
             {
               type = "http";
-              path = "/run/matrix-synapse/user_dir.sock";
+              path = "/run/matrix-synapse/${workerName}.sock";
               resources = [
                 {
                   names = [ "replication" ];
@@ -37,7 +39,7 @@ in
             }
             {
               type = "http";
-              path = "/run/matrix-synapse/user_dir-client.sock";
+              path = "/run/matrix-synapse/${workerName}-client.sock";
               mode = "666";
               resources = [
                 {