nginx -v
nginx -v
nginx version: nginx/1.18.0 (Ubuntu)
Add
client_max_body_size 100M;
# web server port 443 ,# domain with trilium.usdotnet.com
server {
server_name trilium.usdotnet.com; # managed by Certbot
location / {
#frp
if ($host = trilium.usdotnet.com) {
proxy_pass http://wwwiaspnetcorecomfrphostserver;
access_log /var/log/nginx/t.com_https.access.log;
}
# Configuration for LongPolling or if your KeepAliveInterval is longer than 60 seconds
proxy_read_timeout 100s;
proxy_set_header Host $host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
#ws websocket
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_buffering off;
#add file size
proxy_headers_hash_max_size 512;
proxy_headers_hash_bucket_size 128;
client_max_body_size 100M; # 这个最具体,使用100M
}
#listen [::]:443 ssl ipv6only=on; # managed by Certbot
listen 443 ssl; # managed by Certbot
ssl_certificate /etc/letsencrypt/live/ha.com/fullchain.pem; # managed by Certbot
ssl_certificate_key /etc/letsencrypt/live/ha..com/privkey.pem; # managed by Certbot
# include /etc/letsencrypt/options-ssl-nginx.conf; # managed by Certbot
#ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot
}
