From 83dcd0cece658cb9126f92270df7d8761dc2bef1 Mon Sep 17 00:00:00 2001 From: Viyurz <128215328+Viyurz@users.noreply.github.com> Date: Mon, 8 Jan 2024 16:22:22 +0100 Subject: [PATCH] Synapse: Redirect to Element when path not valid. --- nginx-rp/reverse-proxy.conf | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/nginx-rp/reverse-proxy.conf b/nginx-rp/reverse-proxy.conf index c559135..af1c24f 100644 --- a/nginx-rp/reverse-proxy.conf +++ b/nginx-rp/reverse-proxy.conf @@ -168,13 +168,17 @@ server { server_name matrix.viyurz.fr; - location / { + location ~ ^(/_matrix|/_synapse/client) { proxy_pass http://localhost:8008; # Nginx by default only allows file uploads up to 1M in size # Increase client_max_body_size to match max_upload_size defined in homeserver.yaml client_max_body_size 50M; } + + location / { + return 308 https://element.viyurz.fr/; + } }