From 30a54caa03c1ab89167a00b12e46c4bbb920dad5 Mon Sep 17 00:00:00 2001 From: servius Date: Tue, 24 Feb 2026 13:06:04 +0530 Subject: [PATCH] refactor(matrix): update matrix config to Cinny --- nixos/tako/services/matrix/tuwunel.nix | 22 ++++++++-------------- 1 file changed, 8 insertions(+), 14 deletions(-) diff --git a/nixos/tako/services/matrix/tuwunel.nix b/nixos/tako/services/matrix/tuwunel.nix index 61681151..9a6d5fc0 100644 --- a/nixos/tako/services/matrix/tuwunel.nix +++ b/nixos/tako/services/matrix/tuwunel.nix @@ -8,19 +8,12 @@ client_id = "tuwunel"; rtc_domain = "matrix-rtc.${base_domain}"; jwt_port = 8081; - elementConfig = builtins.toJSON { - default_server_config = { - "m.homeserver" = { - base_url = "https://matrix.${base_domain}"; - }; - }; - sso_redirect_options = { - immediate = false; - on_welcome_page = true; - on_login_page = true; - }; + cinnyConfig = builtins.toJSON { + defaultHomeserver = 0; + homeserverList = ["darksailor.dev" "matrix.org"]; + allowCustomHomeservers = false; }; - elementConfigFile = pkgs.writeText "element-config.json" elementConfig; + cinnyConfigFile = pkgs.writeText "cinny-config.json" cinnyConfig; in { sops = { secrets."tuwunel/client_id" = { @@ -78,9 +71,10 @@ in { reverse_proxy /_matrix/* localhost:${toString port} handle_path /config.json { file_server - root ${elementConfigFile} + root ${cinnyConfigFile} } - root * ${pkgs.element-web} + root * ${pkgs.cinny} + try_files {path} / index.html file_server ''; "${base_domain}".extraConfig = ''