2022-01-05 15:43:39 +01:00
|
|
|
# Abuse reports should be sent to Mjölnir.
|
|
|
|
|
2022-05-04 08:35:31 +00:00
|
|
|
location ~ ^/_matrix/client/r0/rooms/([^/]*)/report/(.*)$ {
|
2022-01-05 15:43:39 +01:00
|
|
|
add_header 'Access-Control-Allow-Origin' '*' always;
|
|
|
|
add_header 'Access-Control-Allow-Credentials' 'true' always;
|
|
|
|
add_header 'Access-Control-Allow-Methods' 'GET, POST, OPTIONS' always;
|
|
|
|
add_header 'Access-Control-Allow-Headers' 'Authorization,Content-Type,Accept,Origin,User-Agent,DNT,Cache-Control,X-Mx-ReqToken,Keep-Alive,X-Requested-With,If-Modified-Since' always;
|
|
|
|
add_header 'Access-Control-Expose-Headers' 'Content-Length,Content-Range' always;
|
|
|
|
add_header 'Access-Control-Max-Age' 1728000;
|
|
|
|
|
|
|
|
# Alias the regexps, to ensure that they're not rewritten.
|
|
|
|
set $room_id $1;
|
|
|
|
set $event_id $2;
|
|
|
|
proxy_pass http://127.0.0.1:9002/api/1/report/$room_id/$event_id;
|
|
|
|
}
|