From 14935c5e920ef1f1a72540c17fff419696ac126f Mon Sep 17 00:00:00 2001 From: K900 Date: Mon, 21 Oct 2024 16:31:26 +0300 Subject: [PATCH] fix: update grapevine config --- services/matrix/default.nix | 18 ++++++------------ 1 file changed, 6 insertions(+), 12 deletions(-) diff --git a/services/matrix/default.nix b/services/matrix/default.nix index 4818ebe..3ebc331 100644 --- a/services/matrix/default.nix +++ b/services/matrix/default.nix @@ -32,6 +32,11 @@ in ]; server_name = "forkos.org"; database.backend = "rocksdb"; + + server_discovery = { + server.authority = "matrix.forkos.org:443"; + client.base_url = "https://matrix.forkos.org"; + }; }; }; @@ -48,18 +53,7 @@ in "forkos.org" = { forceSSL = true; enableACME = true; - locations = { - "= /.well-known/matrix/server".extraConfig = '' - add_header Content-Type application/json; - add_header Access-Control-Allow-Origin *; - return 200 '{"m.server": "matrix.forkos.org:443"}'; - ''; - "= /.well-known/matrix/client".extraConfig = '' - add_header Content-Type application/json; - add_header Access-Control-Allow-Origin *; - return 200 '{"m.homeserver": {"base_url": "https://matrix.forkos.org/"}, "m.identity_server": {"base_url": "https://matrix.org/"}, "org.matrix.msc3575.proxy": {"url": "https://matrix.forkos.org"}}'; - ''; - }; + locations."/.well-known/matrix".proxyPass = "http://grapevine"; }; }; };