document nginx needing request_uri

Signed-off-by: strawberry <strawberry@puppygock.gay>
This commit is contained in:
strawberry 2024-10-27 12:19:45 -04:00
parent 52e356d780
commit d92f2c121f
2 changed files with 10 additions and 6 deletions

View File

@ -119,12 +119,16 @@ is the recommended reverse proxy for new users and is very trivial to use
(handles TLS, reverse proxy headers, etc transparently with proper defaults). (handles TLS, reverse proxy headers, etc transparently with proper defaults).
Lighttpd is not supported as it seems to mess with the `X-Matrix` Authorization Lighttpd is not supported as it seems to mess with the `X-Matrix` Authorization
header, making federation non-functional. If using Apache, you need to use header, making federation non-functional. If a workaround is found, feel free to share to get it added to the documentation here.
`nocanon` in your `ProxyPass` directive to prevent this (note that Apache
isn't very good as a general reverse proxy). If using Apache, you need to use `nocanon` in your `ProxyPass` directive to prevent this (note that Apache isn't very good as a general reverse proxy and we discourage the usage of it if you can).
If using Nginx, you need to give conduwuit the request URI using `$request_uri`, or like so:
- `proxy_pass http://127.0.0.1:6167$request_uri;`
- `proxy_pass http://127.0.0.1:6167;`
Nginx users may need to set `proxy_buffering off;` if there are issues with Nginx users may need to set `proxy_buffering off;` if there are issues with
uploading media like images. uploading media like images. This is due to Nginx storing the entire POST content in-memory (`/tmp`) and running out of memory if on low memory hardware.
You will need to reverse proxy everything under following routes: You will need to reverse proxy everything under following routes:
- `/_matrix/` - core Matrix C-S and S-S APIs - `/_matrix/` - core Matrix C-S and S-S APIs

View File

@ -247,8 +247,8 @@ async fn auth_server(services: &Services, request: &mut Request, body: Option<&C
debug_error!("Failed to verify federation request from {origin}: {e}"); debug_error!("Failed to verify federation request from {origin}: {e}");
if request.parts.uri.to_string().contains('@') { if request.parts.uri.to_string().contains('@') {
warn!( warn!(
"Request uri contained '@' character. Make sure your reverse proxy gives Conduit the raw uri (apache: \ "Request uri contained '@' character. Make sure your reverse proxy gives conduwuit the raw uri \
use nocanon)" (apache: use nocanon)"
); );
} }