From f22656116faa127b31bbf3bf1d778c96d4f3e7d5 Mon Sep 17 00:00:00 2001 From: harveyshao Date: Fri, 25 Feb 2022 19:56:44 +0800 Subject: [PATCH] opt some --- etc/conf/nginx.conf | 70 ++++++++++++++++++++++----------------------- 1 file changed, 35 insertions(+), 35 deletions(-) diff --git a/etc/conf/nginx.conf b/etc/conf/nginx.conf index 1e0640f1..b9638992 100644 --- a/etc/conf/nginx.conf +++ b/etc/conf/nginx.conf @@ -3,55 +3,55 @@ user shy; worker_processes 1; events { - worker_connections 1024; + worker_connections 1024; } http { - include mime.types; - default_type application/octet-stream; - keepalive_timeout 1800; + include mime.types; + default_type application/octet-stream; + keepalive_timeout 1800; - sendfile on; - proxy_buffering off; + sendfile on; + proxy_buffering off; - server { - listen 80; - server_name shylinux.com; + server { + listen 80; + server_name shylinux.com; location / { return 302 https://shylinux.com/; } - } + } - server { - listen 443 ssl; - server_name shylinux.com; + server { + listen 443 ssl; + server_name shylinux.com; - ssl_certificate 6157098_shylinux.com.pem; - ssl_certificate_key 6157098_shylinux.com.key; + ssl_certificate 6157098_shylinux.com.pem; + ssl_certificate_key 6157098_shylinux.com.key; - ssl_session_cache shared:SSL:1m; - ssl_session_timeout 30m; + ssl_session_cache shared:SSL:1m; + ssl_session_timeout 30m; - ssl_ciphers HIGH:!aNULL:!MD5; - ssl_prefer_server_ciphers on; + ssl_ciphers HIGH:!aNULL:!MD5; + ssl_prefer_server_ciphers on; - client_max_body_size 100m; + client_max_body_size 100m; - location / { - proxy_pass http://127.0.0.1:9020; - proxy_set_header X-HOST $scheme://$http_host; - proxy_set_header X-Real-Port $remote_port; - proxy_set_header X-Real-IP $remote_addr; - } + location / { + proxy_pass http://127.0.0.1:9020; + proxy_set_header X-HOST $scheme://$http_host; + proxy_set_header X-Real-Port $remote_port; + proxy_set_header X-Real-IP $remote_addr; + } - location /space/ { - proxy_pass http://127.0.0.1:9020; - proxy_set_header X-HOST $scheme://$http_host; - proxy_set_header X-Real-Port $remote_port; - proxy_set_header X-Real-IP $remote_addr; - proxy_set_header Upgrade $http_upgrade; - proxy_set_header Connection "upgrade"; - } - } + location /space/ { + proxy_pass http://127.0.0.1:9020; + proxy_set_header X-HOST $scheme://$http_host; + proxy_set_header X-Real-Port $remote_port; + proxy_set_header X-Real-IP $remote_addr; + proxy_set_header Upgrade $http_upgrade; + proxy_set_header Connection "upgrade"; + } + } }