forked from exozyme/nginx
38 lines
827 B
Text
38 lines
827 B
Text
server {
|
|
listen 80 default_server;
|
|
listen [::]:80 default_server;
|
|
|
|
location / {
|
|
return 301 https://$host$request_uri;
|
|
}
|
|
}
|
|
|
|
server {
|
|
listen 443 ssl default_server;
|
|
listen [::]:443 ssl default_server;
|
|
|
|
server_name exozy.me;
|
|
|
|
include conf.d/ssl;
|
|
|
|
root /srv/http/exozyme;
|
|
index index.html;
|
|
|
|
location /.well-known/matrix/server {
|
|
return 200 '{"m.server": "chat.exozy.me:443"}';
|
|
}
|
|
|
|
location /.well-known/matrix/client {
|
|
return 200 '{"m.homeserver": {"base_url": "https://chat.exozy.me"}}';
|
|
default_type application/json;
|
|
add_header Access-Control-Allow-Origin *;
|
|
}
|
|
|
|
location /.well-known/webfinger {
|
|
return 301 https://social.exozy.me$request_uri;
|
|
}
|
|
|
|
location / {
|
|
try_files $uri $uri.html $uri/ =404;
|
|
}
|
|
}
|