Compare commits

...

1 Commits

Author SHA1 Message Date
yukkop 92b2e579cc fix: matrix hardcode 2026-07-01 09:43:36 +00:00
@@ -9,17 +9,11 @@
config, config,
... ...
}: let }: let
matrixBackend = "https://128.140.75.58";
matrixHost = "accord.tube"; matrixHost = "accord.tube";
jitsiHost = "meet.accord.tube"; jitsiHost = "meet.accord.tube";
elementEntryDomain = "element.bfs.band"; elementEntryDomain = "element.bfs.band";
polandEntryDomain = "bfs.band"; polandEntryDomain = "bfs.band";
matrixClusterSopsFile = flake + "/sus/matrix-cluster.yaml"; matrixClusterSopsFile = flake + "/sus/matrix-cluster.yaml";
backendProxyConfig = ''
proxy_ssl_server_name on;
proxy_ssl_name ${matrixHost};
proxy_set_header Host ${matrixHost};
'';
in { in {
imports = [ imports = [
self.nixosModules.xray-system self.nixosModules.xray-system
@@ -47,7 +41,6 @@ in {
credentialsFile = config.sops.secrets."matrix/object-storage/credentials".path; credentialsFile = config.sops.secrets."matrix/object-storage/credentials".path;
}; };
replication = { replication = {
peerHost = "128.140.75.58";
passwordFile = config.sops.secrets."matrix/postgres-replication-password".path; passwordFile = config.sops.secrets."matrix/postgres-replication-password".path;
}; };
acme = { acme = {
@@ -133,19 +126,17 @@ in {
}; };
locations."= /livekit/jwt" = { locations."= /livekit/jwt" = {
proxyPass = "${matrixBackend}/livekit/jwt"; proxyPass = "http://[::1]:${toString config.services.lk-jwt-service.port}/";
extraConfig = backendProxyConfig;
}; };
locations."^~ /livekit/jwt/" = { locations."^~ /livekit/jwt/" = {
proxyPass = "${matrixBackend}/livekit/jwt/"; proxyPass = "http://[::1]:${toString config.services.lk-jwt-service.port}/";
extraConfig = backendProxyConfig;
}; };
locations."= /livekit/sfu" = { locations."= /livekit/sfu" = {
proxyPass = "${matrixBackend}/livekit/sfu"; proxyPass = "http://[::1]:${toString config.services.livekit.settings.port}/";
proxyWebsockets = true; proxyWebsockets = true;
extraConfig = backendProxyConfig + '' extraConfig = ''
proxy_send_timeout 120; proxy_send_timeout 120;
proxy_read_timeout 120; proxy_read_timeout 120;
proxy_buffering off; proxy_buffering off;
@@ -156,9 +147,9 @@ in {
}; };
locations."^~ /livekit/sfu/" = { locations."^~ /livekit/sfu/" = {
proxyPass = "${matrixBackend}/livekit/sfu/"; proxyPass = "http://[::1]:${toString config.services.livekit.settings.port}/";
proxyWebsockets = true; proxyWebsockets = true;
extraConfig = backendProxyConfig + '' extraConfig = ''
proxy_send_timeout 120; proxy_send_timeout 120;
proxy_read_timeout 120; proxy_read_timeout 120;
proxy_buffering off; proxy_buffering off;
@@ -169,13 +160,14 @@ in {
}; };
locations."^~ /_matrix/" = { locations."^~ /_matrix/" = {
proxyPass = "${matrixBackend}/_matrix/"; proxyPass = "http://127.0.0.1:8008";
extraConfig = backendProxyConfig; extraConfig = ''
client_max_body_size ${config.hectic.generic.matrix-cluster.maxUploadSize};
'';
}; };
locations."^~ /_synapse/client/" = { locations."^~ /_synapse/client/" = {
proxyPass = "${matrixBackend}/_synapse/client/"; proxyPass = "http://127.0.0.1:8008";
extraConfig = backendProxyConfig;
}; };
}; };