Compare commits
6 Commits
6131970724
...
b032364616
| Author | SHA1 | Date |
|---|---|---|
|
|
b032364616 | |
|
|
a430aaee97 | |
|
|
f4ee2ca3b9 | |
|
|
92b9212b31 | |
|
|
73656e60ff | |
|
|
401329d80c |
|
|
@ -37,8 +37,8 @@ http
|
|||
client_max_body_size 20m;
|
||||
|
||||
# video big file opt
|
||||
aio threads;
|
||||
directio 4m;
|
||||
#aio threads;
|
||||
#directio 4m;
|
||||
output_buffers 16 512k;
|
||||
sendfile on;
|
||||
tcp_nopush on;
|
||||
|
|
@ -55,18 +55,18 @@ http
|
|||
fastcgi_temp_file_write_size 256k;
|
||||
fastcgi_intercept_errors on;
|
||||
|
||||
zstd off;
|
||||
zstd_comp_level 6;
|
||||
zstd_min_length 256;
|
||||
zstd_types text/plain text/css text/xml text/javascript text/cache-manifest text/x-component text/vtt application/javascript application/json application/ld+json application/xml application/xhtml+xml application/rss+xml application/atom+xml application/manifest+json application/x-web-app-manifest+json application/vnd.geo+json application/vnd.ms-fontobject application/x-font-ttf application/wasm font/opentype image/svg+xml image/bmp;
|
||||
#zstd off;
|
||||
#zstd_comp_level 6;
|
||||
#zstd_min_length 256;
|
||||
#zstd_types text/plain text/css text/xml text/javascript text/cache-manifest text/x-component text/vtt application/javascript application/json application/ld+json application/xml application/xhtml+xml application/rss+xml application/atom+xml application/manifest+json application/x-web-app-manifest+json application/vnd.geo+json application/vnd.ms-fontobject application/x-font-ttf application/wasm font/opentype image/svg+xml image/bmp;
|
||||
|
||||
brotli off;
|
||||
brotli_min_length 256;
|
||||
brotli_buffers 32 8k;
|
||||
brotli_comp_level 4;
|
||||
brotli_window 16m;
|
||||
brotli_static on;
|
||||
brotli_types text/plain text/css text/xml text/javascript text/x-component application/javascript application/x-javascript application/json application/xml application/rss+xml application/atom+xml application/vnd.ms-fontobject application/x-font-ttf application/x-font-opentype application/x-font-truetype font/tpl font/opentype font/otf font/ttf image/svg+xml image/x-icon image/vnd.microsoft.icon application/wasm application/manifest+json;
|
||||
#brotli off;
|
||||
#brotli_min_length 256;
|
||||
#brotli_buffers 32 8k;
|
||||
#brotli_comp_level 4;
|
||||
#brotli_window 16m;
|
||||
#brotli_static on;
|
||||
#brotli_types text/plain text/css text/xml text/javascript text/x-component application/javascript application/x-javascript application/json application/xml application/rss+xml application/atom+xml application/vnd.ms-fontobject application/x-font-ttf application/x-font-opentype application/x-font-truetype font/tpl font/opentype font/otf font/ttf image/svg+xml image/x-icon image/vnd.microsoft.icon application/wasm application/manifest+json;
|
||||
|
||||
gzip on;
|
||||
gzip_min_length 1k;
|
||||
|
|
|
|||
|
|
@ -577,6 +577,31 @@ def setCfg():
|
|||
if not re.search(r"\d+", v):
|
||||
return mw.returnJson(False, '参数值错误,请输入数字整数')
|
||||
|
||||
if k == "brotli":
|
||||
if v == "on":
|
||||
# 批量替换所有以 #brotli 等开头的指令为 brotli
|
||||
rep_var = r"#+brotli[\w_]*\s+[^\;\n]+"
|
||||
newconf = lambda m: m.group(0).lstrip('#')
|
||||
content = re.sub(rep_var, newconf, content)
|
||||
if v == "off":
|
||||
# 批量替换所有以 brotli 开头且没有 # 前缀的指令为 #brotli
|
||||
rep_var = r"(?<!#)brotli[\w_]*\s+[^\;\n]+"
|
||||
newconf = lambda m: '#' + m.group(0)
|
||||
content = re.sub(rep_var, newconf, content)
|
||||
|
||||
|
||||
if k == "zstd":
|
||||
if v == "on":
|
||||
# 批量替换所有以 #zstd 开头的指令为 zstd
|
||||
rep_var = r"#+zstd[\w_]*\s+[^\;\n]+"
|
||||
newconf = lambda m: m.group(0).lstrip('#')
|
||||
content = re.sub(rep_var, newconf, content)
|
||||
if v == "off":
|
||||
# 批量替换所有以 zstd 开头且没有 # 前缀的指令为 #zstd
|
||||
rep_var = r"(?<!#)zstd[\w_]*\s+[^\;\n]+"
|
||||
newconf = lambda m: '#' + m.group(0)
|
||||
content = re.sub(rep_var, newconf, content)
|
||||
|
||||
if k == "worker_processes" :
|
||||
k_wca = "worker_cpu_affinity"
|
||||
rep_wca = r"%s\s+[^\;\n]+" % k_wca
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin:~/bin:/opt/homebrew/bin
|
||||
export PATH
|
||||
|
||||
# cd /Users/midoks/Desktop/mwdev/server/mdserver-web/plugins/openresty && bash install.sh install 1.21.4
|
||||
# cd /Users/midoks/Desktop/mwdev/server/mdserver-web/plugins/openresty && bash install.sh upgrade 1.29.2
|
||||
# cd /www/server/mdserver-web/plugins/openresty && bash install.sh install 1.21.4
|
||||
# cd /www/server/mdserver-web/plugins/openresty && bash install.sh install 1.29.2
|
||||
# cd /www/server/mdserver-web/plugins/openresty && bash install.sh upgrade 1.29.2
|
||||
|
|
|
|||
|
|
@ -133,14 +133,22 @@ Install_openresty()
|
|||
fi
|
||||
|
||||
OPTIONS="${OPTIONS} --with-threads"
|
||||
OPTIONS="${OPTIONS} --with-file-aio"
|
||||
OPTIONS="${OPTIONS} --with-pcre-jit"
|
||||
OPTIONS="${OPTIONS} --with-http_gzip_static_module"
|
||||
|
||||
if [ ! -d ${openrestyDir}/zstd-nginx-module ];then
|
||||
if [ "$sysName" != "Darwin" ];then
|
||||
OPTIONS="${OPTIONS} --with-file-aio"
|
||||
fi
|
||||
|
||||
if [ ! -d ${openrestyDir}/zstd-nginx-module-master ];then
|
||||
cd ${openrestyDir} && wget -O $openrestyDir/zstd-nginx-module.tar.gz https://github.com/tokers/zstd-nginx-module/archive/refs/heads/master.tar.gz
|
||||
cd ${openrestyDir} && tar -zxvf zstd-nginx-module.tar.gz
|
||||
|
||||
if [ "$sysName" == "Darwin" ];then
|
||||
export ZSTD_INC=/opt/homebrew/include
|
||||
export ZSTD_LIB=/opt/homebrew/lib
|
||||
fi
|
||||
|
||||
pkg-config --exists --print-errors libzstd
|
||||
if [ "$?" == "0" ];then
|
||||
OPTIONS="${OPTIONS} --add-module=${openrestyDir}/zstd-nginx-module-master"
|
||||
|
|
|
|||
|
|
@ -134,14 +134,22 @@ Install_openresty()
|
|||
fi
|
||||
|
||||
OPTIONS="${OPTIONS} --with-threads"
|
||||
OPTIONS="${OPTIONS} --with-file-aio"
|
||||
OPTIONS="${OPTIONS} --with-pcre-jit"
|
||||
OPTIONS="${OPTIONS} --with-http_gzip_static_module"
|
||||
|
||||
if [ ! -d ${openrestyDir}/zstd-nginx-module ];then
|
||||
if [ "$sysName" != "Darwin" ];then
|
||||
OPTIONS="${OPTIONS} --with-file-aio"
|
||||
fi
|
||||
|
||||
if [ ! -d ${openrestyDir}/zstd-nginx-module-master ];then
|
||||
cd ${openrestyDir} && wget -O $openrestyDir/zstd-nginx-module.tar.gz https://github.com/tokers/zstd-nginx-module/archive/refs/heads/master.tar.gz
|
||||
cd ${openrestyDir} && tar -zxvf zstd-nginx-module.tar.gz
|
||||
|
||||
if [ "$sysName" == "Darwin" ];then
|
||||
export ZSTD_INC=/opt/homebrew/include
|
||||
export ZSTD_LIB=/opt/homebrew/lib
|
||||
fi
|
||||
|
||||
pkg-config --exists --print-errors libzstd
|
||||
if [ "$?" == "0" ];then
|
||||
OPTIONS="${OPTIONS} --add-module=${openrestyDir}/zstd-nginx-module-master"
|
||||
|
|
|
|||
|
|
@ -133,14 +133,22 @@ Install_openresty()
|
|||
fi
|
||||
|
||||
OPTIONS="${OPTIONS} --with-threads"
|
||||
OPTIONS="${OPTIONS} --with-file-aio"
|
||||
OPTIONS="${OPTIONS} --with-pcre-jit"
|
||||
OPTIONS="${OPTIONS} --with-http_gzip_static_module"
|
||||
|
||||
if [ ! -d ${openrestyDir}/zstd-nginx-module ];then
|
||||
if [ "$sysName" != "Darwin" ];then
|
||||
OPTIONS="${OPTIONS} --with-file-aio"
|
||||
fi
|
||||
|
||||
if [ ! -d ${openrestyDir}/zstd-nginx-module-master ];then
|
||||
cd ${openrestyDir} && wget -O $openrestyDir/zstd-nginx-module.tar.gz https://github.com/tokers/zstd-nginx-module/archive/refs/heads/master.tar.gz
|
||||
cd ${openrestyDir} && tar -zxvf zstd-nginx-module.tar.gz
|
||||
|
||||
if [ "$sysName" == "Darwin" ];then
|
||||
export ZSTD_INC=/opt/homebrew/include
|
||||
export ZSTD_LIB=/opt/homebrew/lib
|
||||
fi
|
||||
|
||||
pkg-config --exists --print-errors libzstd
|
||||
if [ "$?" == "0" ];then
|
||||
OPTIONS="${OPTIONS} --add-module=${openrestyDir}/zstd-nginx-module-master"
|
||||
|
|
|
|||
|
|
@ -149,14 +149,22 @@ Install_openresty()
|
|||
fi
|
||||
|
||||
OPTIONS="${OPTIONS} --with-threads"
|
||||
OPTIONS="${OPTIONS} --with-file-aio"
|
||||
OPTIONS="${OPTIONS} --with-pcre-jit"
|
||||
OPTIONS="${OPTIONS} --with-http_gzip_static_module"
|
||||
|
||||
if [ ! -d ${openrestyDir}/zstd-nginx-module ];then
|
||||
if [ "$sysName" != "Darwin" ];then
|
||||
OPTIONS="${OPTIONS} --with-file-aio"
|
||||
fi
|
||||
|
||||
if [ ! -d ${openrestyDir}/zstd-nginx-module-master ];then
|
||||
cd ${openrestyDir} && wget -O $openrestyDir/zstd-nginx-module.tar.gz https://github.com/tokers/zstd-nginx-module/archive/refs/heads/master.tar.gz
|
||||
cd ${openrestyDir} && tar -zxvf zstd-nginx-module.tar.gz
|
||||
|
||||
if [ "$sysName" == "Darwin" ];then
|
||||
export ZSTD_INC=/opt/homebrew/include
|
||||
export ZSTD_LIB=/opt/homebrew/lib
|
||||
fi
|
||||
|
||||
pkg-config --exists --print-errors libzstd
|
||||
if [ "$?" == "0" ];then
|
||||
OPTIONS="${OPTIONS} --add-module=${openrestyDir}/zstd-nginx-module-master"
|
||||
|
|
|
|||
|
|
@ -132,22 +132,31 @@ Install_openresty()
|
|||
fi
|
||||
|
||||
# br
|
||||
if [ ! -d ${openrestyDir}/openresty-${VERSION}/ngx_brotli ];then
|
||||
cd ${openrestyDir}/openresty-${VERSION} && git clone https://github.com/wxx9248/ngx_brotli.git
|
||||
cd ${openrestyDir}/openresty-${VERSION}/ngx_brotli && git submodule update --init
|
||||
if [ ! -d ${openrestyDir}/ngx_brotli ];then
|
||||
cd ${openrestyDir} && git clone https://github.com/wxx9248/ngx_brotli.git
|
||||
cd ${openrestyDir}/ngx_brotli && git submodule update --init
|
||||
|
||||
OPTIONS="${OPTIONS} --add-module=${openrestyDir}/openresty-${VERSION}/ngx_brotli"
|
||||
OPTIONS="${OPTIONS} --add-module=${openrestyDir}/ngx_brotli"
|
||||
fi
|
||||
|
||||
OPTIONS="${OPTIONS} --with-threads"
|
||||
OPTIONS="${OPTIONS} --with-file-aio"
|
||||
OPTIONS="${OPTIONS} --with-pcre-jit"
|
||||
OPTIONS="${OPTIONS} --with-http_gzip_static_module"
|
||||
|
||||
if [ ! -d ${openrestyDir}/zstd-nginx-module ];then
|
||||
|
||||
if [ "$sysName" != "Darwin" ];then
|
||||
OPTIONS="${OPTIONS} --with-file-aio"
|
||||
fi
|
||||
|
||||
if [ ! -d ${openrestyDir}/zstd-nginx-module-master ];then
|
||||
cd ${openrestyDir} && wget -O $openrestyDir/zstd-nginx-module.tar.gz https://github.com/tokers/zstd-nginx-module/archive/refs/heads/master.tar.gz
|
||||
cd ${openrestyDir} && tar -zxvf zstd-nginx-module.tar.gz
|
||||
|
||||
if [ "$sysName" == "Darwin" ];then
|
||||
export ZSTD_INC=/opt/homebrew/include
|
||||
export ZSTD_LIB=/opt/homebrew/lib
|
||||
fi
|
||||
|
||||
pkg-config --exists --print-errors libzstd
|
||||
if [ "$?" == "0" ];then
|
||||
OPTIONS="${OPTIONS} --add-module=${openrestyDir}/zstd-nginx-module-master"
|
||||
|
|
|
|||
|
|
@ -140,15 +140,23 @@ Install_openresty()
|
|||
fi
|
||||
|
||||
OPTIONS="${OPTIONS} --with-threads"
|
||||
OPTIONS="${OPTIONS} --with-file-aio"
|
||||
OPTIONS="${OPTIONS} --with-pcre-jit"
|
||||
OPTIONS="${OPTIONS} --with-http_gzip_static_module"
|
||||
|
||||
if [ "$sysName" != "Darwin" ];then
|
||||
OPTIONS="${OPTIONS} --with-file-aio"
|
||||
fi
|
||||
|
||||
#zstd
|
||||
if [ ! -d ${openrestyDir}/zstd-nginx-module ];then
|
||||
if [ ! -d ${openrestyDir}/zstd-nginx-module-master ];then
|
||||
cd ${openrestyDir} && wget -O $openrestyDir/zstd-nginx-module.tar.gz https://github.com/tokers/zstd-nginx-module/archive/refs/heads/master.tar.gz
|
||||
cd ${openrestyDir} && tar -zxvf zstd-nginx-module.tar.gz
|
||||
|
||||
if [ "$sysName" == "Darwin" ];then
|
||||
export ZSTD_INC=/opt/homebrew/include
|
||||
export ZSTD_LIB=/opt/homebrew/lib
|
||||
fi
|
||||
|
||||
pkg-config --exists --print-errors libzstd
|
||||
if [ "$?" == "0" ];then
|
||||
OPTIONS="${OPTIONS} --add-module=${openrestyDir}/zstd-nginx-module-master"
|
||||
|
|
@ -195,9 +203,9 @@ Install_openresty()
|
|||
rm -rf $openrestyDir/openresty-${VERSION}
|
||||
fi
|
||||
|
||||
if [ -d $openrestyDir/zstd-nginx-module-master ];then
|
||||
rm -rf $openrestyDir/zstd-nginx-module-master
|
||||
fi
|
||||
# if [ -d $openrestyDir/zstd-nginx-module-master ];then
|
||||
# rm -rf $openrestyDir/zstd-nginx-module-master
|
||||
# fi
|
||||
|
||||
# if [ -d $openrestyDir/ngx_brotli ];then
|
||||
# rm -rf $openrestyDir/ngx_brotli
|
||||
|
|
|
|||
|
|
@ -59,10 +59,6 @@ def send_msg(bot, tag='ad', trigger_time=300):
|
|||
],
|
||||
[
|
||||
types.InlineKeyboardButton(
|
||||
text="代付-代实名-备案域名-国际云服务器", url='https://t.me/gjgzs2022')
|
||||
],
|
||||
[
|
||||
types.InlineKeyboardButton(
|
||||
text="实名认证/过人脸🕵️♀️各种账号处理✅", url='https://t.me/niuniu234')
|
||||
],
|
||||
[
|
||||
|
|
|
|||
|
|
@ -54,7 +54,6 @@ def send_msg(bot, tag='ad', trigger_time=300):
|
|||
mw.writeFile(lock_file, json.dumps(lock_data))
|
||||
# 信号只在一个周期内执行一次|end
|
||||
|
||||
# https://t.me/gjgzs2022 | 22/m | @GJ_gzs
|
||||
# 实名认证/过人脸🕵️♀️各种账号处理✅ | 30/m| next,6/30 | @nngzs
|
||||
# 18+资源采集| 4/m | next,7/14 | @liuxingyu123
|
||||
# 海内外实名KYC-执照代付✅域名| 17/m | next,6/17 | @kdgzs
|
||||
|
|
@ -74,10 +73,6 @@ def send_msg(bot, tag='ad', trigger_time=300):
|
|||
],
|
||||
[
|
||||
types.InlineKeyboardButton(
|
||||
text="代付-代实名-备案域名-国际云服务器", url='https://t.me/gjgzs2022')
|
||||
],
|
||||
[
|
||||
types.InlineKeyboardButton(
|
||||
text="实名认证/过人脸🕵️♀️各种账号处理✅", url='https://t.me/niuniu234')
|
||||
],
|
||||
[
|
||||
|
|
|
|||
Loading…
Reference in New Issue