31 lines
911 B
Plaintext
31 lines
911 B
Plaintext
server {
|
|
listen 443 ssl http2;
|
|
listen [::]:443 ssl http2;
|
|
listen 8448 ssl http2;
|
|
listen [::]:8448 ssl http2;
|
|
server_name matrix.aryak.ml;
|
|
merge_slashes off;
|
|
|
|
location /_matrix/ {
|
|
proxy_pass http://10.7.0.4:6167$request_uri;
|
|
proxy_set_header Host $http_host;
|
|
proxy_buffering off;
|
|
}
|
|
ssl_certificate /etc/letsencrypt/live/matrix.aryak.ml/fullchain.pem; # EDIT THIS
|
|
ssl_certificate_key /etc/letsencrypt/live/matrix.aryak.ml/privkey.pem; # EDIT THIS
|
|
|
|
|
|
location /.well-known/matrix/server {
|
|
add_header Access-Control-Allow-Origin '*' always;
|
|
add_header Content-Type application/json;
|
|
return 200 '{"m.server": "matrix.aryak.ml:443"}';
|
|
}
|
|
|
|
location /.well-known/matrix/client {
|
|
add_header Access-Control-Allow-Origin '*' always;
|
|
add_header Content-Type application/json;
|
|
return 200 '{"m.homeserver": {"base_url": "https://matrix.aryak.ml"}}';
|
|
}
|
|
}
|
|
|