From 96640ee0a3d729bd6a855a79e3a1a0a9f44efc86 Mon Sep 17 00:00:00 2001 From: mack-a <57424792+mack-a@users.noreply.github.com> Date: Sun, 24 May 2020 21:10:55 +0800 Subject: [PATCH] =?UTF-8?q?feat(=E4=B8=80=E9=94=AE=E8=84=9A=E6=9C=AC):=20?= =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E5=8D=9A=E5=AE=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- install.sh | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/install.sh b/install.sh index 885b828..348c1cc 100644 --- a/install.sh +++ b/install.sh @@ -62,6 +62,7 @@ installTools(){ removeLog=`${removeType} nginx` fi rm -rf /etc/nginx/nginx.conf + rm -rf /usr/share/nginx/html.zip fi if [[ ! -z `find /usr/bin/ -name "v2ray*"` ]] @@ -218,8 +219,8 @@ installTLS(){ # sed -i "${nginxInstallLine}i server {listen 443 ssl;server_name $1;root /usr/share/nginx/html;ssl_certificate /etc/nginx/$1.crt;ssl_certificate_key /etc/nginx/$1.key;ssl_protocols TLSv1 TLSv1.1 TLSv1.2;ssl_ciphers ECDHE-RSA-AES128-GCM-SHA256:ECDHE:ECDH:AES:HIGH:!NULL:!aNULL:!MD5:!ADH:!RC4;ssl_prefer_server_ciphers on;location / {} location /alone { proxy_redirect off;proxy_pass http://127.0.0.1:31299;proxy_http_version 1.1;proxy_set_header Upgrade \$http_upgrade;proxy_set_header Connection "upgrade";proxy_set_header X-Real-IP \$remote_addr;proxy_set_header Host \$host;proxy_set_header X-Forwarded-For \$proxy_add_x_forwarded_for;}}" /etc/nginx/nginx.conf echo "server {listen 443 ssl;server_name $1;root /usr/share/nginx/html;ssl_certificate /etc/nginx/$1.crt;ssl_certificate_key /etc/nginx/$1.key;ssl_protocols TLSv1 TLSv1.1 TLSv1.2;ssl_ciphers ECDHE-RSA-AES128-GCM-SHA256:ECDHE:ECDH:AES:HIGH:!NULL:!aNULL:!MD5:!ADH:!RC4;ssl_prefer_server_ciphers on;location / {} location /alone { proxy_redirect off;proxy_pass http://127.0.0.1:31299;proxy_http_version 1.1;proxy_set_header Upgrade \$http_upgrade;proxy_set_header Connection "upgrade";proxy_set_header X-Real-IP \$remote_addr;proxy_set_header Host \$host;proxy_set_header X-Forwarded-For \$proxy_add_x_forwarded_for;}}" > /etc/nginx/conf.d/alone.conf rm -rf /usr/share/nginx/html - wget -P https://raw.githubusercontent.com/mack-a/v2ray-agent/master/blog/unable/html.zip /usr/share/nginx >> /dev/null - unzip /usr/share/nginx/html.zip -d /usr/share/nginx/ + wget -P /usr/share/nginx https://raw.githubusercontent.com/mack-a/v2ray-agent/master/blog/unable/html.zip >> /dev/null + unzip /usr/share/nginx/html.zip -d /usr/share/nginx/html nginx if [[ -z `ps -ef|grep -v grep|grep nginx` ]] then