From 9f50b69cc4864941776be3d73496bf658e73dad4 Mon Sep 17 00:00:00 2001 From: HITSword Date: Wed, 8 Jan 2020 18:30:35 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: HITSword --- AMHScript | 2 +- hyproxy-cli.php | 10 ++++++++++ 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/AMHScript b/AMHScript index 817324e..e0b2639 100644 --- a/AMHScript +++ b/AMHScript @@ -27,7 +27,7 @@ function amh_module_install() rm -rf /root/amh/modules/$module_name; done; #Delete conflict modules - if [ -f "/root/amh/modules/limit_req2_nginx_module-1.2/InstallComplete" ]; then + if ls /root/amh/modules/ | grep -q 'limit_req2_nginx_module-1.2'; then amh module limit_req2_nginx_module-1.2 uninstall force; amh module limit_req2_nginx_module-1.2 delete y; fi; diff --git a/hyproxy-cli.php b/hyproxy-cli.php index 9f44b7a..a8f6a3b 100644 --- a/hyproxy-cli.php +++ b/hyproxy-cli.php @@ -97,6 +97,11 @@ function hyproxy_make($server_name){//done server_name %s; index %s; + #error_page + location /ErrorPages/ { + alias /home/wwwroot/index/etc/html/ErrorPages/; + } + location / { default_type text/html; proxy_cache hyproxy; @@ -120,6 +125,11 @@ function hyproxy_make($server_name){//done server_name %s; index %s; + #error_page + location /ErrorPages/ { + alias /home/wwwroot/index/etc/html/ErrorPages/; + } + location / { default_type text/html; proxy_set_header X-Real-IP $remote_addr;