add synapse-admin

This commit is contained in:
Moritz
2025-01-28 17:42:07 +01:00
parent 7c0e822940
commit a90ccaa65b
6 changed files with 72 additions and 2 deletions

View File

@ -36,5 +36,20 @@ http {
default_type application/json;
add_header Access-Control-Allow-Origin *;
}
{{ if eq (env "ADMIN_INTERFACE_ENABLED") "1" }}
location ^~ /_synapse/admin {
if ($http_referer !~ "^https://{{ env "DOMAIN" }}/admin/") {
return 403;
}
proxy_pass http://{{ env "STACK_NAME"}}_app:8008;
proxy_set_header X-Forwarded-For $remote_addr;
proxy_set_header X-Forwarded-Proto https;
proxy_set_header Host $host;
client_max_body_size 50M;
proxy_http_version 1.1;
}
{{ end }}
}
}