update
This commit is contained in:
parent
2832ff81f3
commit
116a404c0b
32 changed files with 934 additions and 661 deletions
60
nginx/synapse.stpl
Executable file
60
nginx/synapse.stpl
Executable file
|
|
@ -0,0 +1,60 @@
|
|||
#=========================================================================#
|
||||
# Default Web Domain Template #
|
||||
# DO NOT MODIFY THIS FILE! CHANGES WILL BE LOST WHEN REBUILDING DOMAINS #
|
||||
# https://hestiacp.com/docs/server-administration/web-templates.html #
|
||||
#=========================================================================#
|
||||
|
||||
server {
|
||||
listen %ip%:%proxy_ssl_port% ssl;
|
||||
listen [::]:%proxy_ssl_port% ssl;
|
||||
server_name %domain_idn% %alias_idn%;
|
||||
error_log /var/log/%web_system%/domains/%domain%.error.log error;
|
||||
|
||||
ssl_certificate %ssl_pem%;
|
||||
ssl_certificate_key %ssl_key%;
|
||||
ssl_stapling on;
|
||||
ssl_stapling_verify on;
|
||||
|
||||
# TLS 1.3 0-RTT anti-replay
|
||||
if ($anti_replay = 307) { return 307 https://$host$request_uri; }
|
||||
if ($anti_replay = 425) { return 425; }
|
||||
|
||||
include %home%/%user%/conf/web/%domain%/nginx.hsts.conf*;
|
||||
|
||||
location ~ /\.(?!well-known\/|file) {
|
||||
deny all;
|
||||
return 404;
|
||||
}
|
||||
|
||||
gzip on;
|
||||
gzip_vary on;
|
||||
gzip_comp_level 4;
|
||||
gzip_min_length 256;
|
||||
gzip_proxied expired no-cache no-store private no_last_modified no_etag auth;
|
||||
gzip_types application/atom+xml application/javascript application/json application/ld+json application/manifest+json application/rss+xml application/vnd.geo+json application/vnd.ms-fontobject application/x-font-ttf application/x-web-app-manifest+json application/xhtml+xml application/xml font/opentype image/bmp image/svg+xml image/x-icon text/cache-manifest text/css text/plain text/vcard text/vnd.rim.location.xloc text/vtt text/x-component text/x-cross-domain-policy;
|
||||
|
||||
location / {
|
||||
proxy_pass http://127.0.0.1:6080;
|
||||
proxy_set_header X-Forwarded-For $remote_addr;
|
||||
# Nginx by default only allows file uploads up to 1M in size
|
||||
# Increase client_max_body_size to match max_upload_size defined in homeserver.yaml
|
||||
}
|
||||
|
||||
location /.well-known/matrix/client {
|
||||
return 200 '{"m.homeserver": {"base_url": "https://im.kernel.ws"}}';
|
||||
default_type application/json;
|
||||
add_header Access-Control-Allow-Origin *;
|
||||
}
|
||||
location ~* ^(\/_matrix|\/_synapse) {
|
||||
proxy_pass http://127.0.0.1:8008;
|
||||
proxy_set_header X-Forwarded-For $remote_addr;
|
||||
# Nginx by default only allows file uploads up to 1M in size
|
||||
# Increase client_max_body_size to match max_upload_size defined in homeserver.yaml
|
||||
}
|
||||
location /admin/ {
|
||||
proxy_pass http://127.0.0.1:8100/;
|
||||
proxy_set_header X-Forwarded-For $remote_addr;
|
||||
}
|
||||
|
||||
include %home%/%user%/conf/web/%domain%/nginx.ssl.conf_*;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue