Skip to content

Commit b05aec6

Browse files
committed
Force sing-box vesion to 1.11.0-alpha.6
1 parent a2dffc7 commit b05aec6

File tree

2 files changed

+12
-8
lines changed

2 files changed

+12
-8
lines changed

docker_init.sh

+8-5
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,8 @@ check_latest_sing-box() {
3636
install() {
3737
# 下载 sing-box
3838
echo "正在下载 sing-box ..."
39-
local ONLINE=$(check_latest_sing-box)
39+
#####local ONLINE=$(check_latest_sing-box)
40+
local ONLINE='1.11.0-alpha.6'
4041
wget https://github.com/SagerNet/sing-box/releases/download/v$ONLINE/sing-box-$ONLINE-linux-$SING_BOX_ARCH.tar.gz -O- | tar xz -C $WORK_DIR sing-box-$ONLINE-linux-$SING_BOX_ARCH/sing-box && mv $WORK_DIR/sing-box-$ONLINE-linux-$SING_BOX_ARCH/sing-box $WORK_DIR/sing-box && rm -rf $WORK_DIR/sing-box-$ONLINE-linux-$SING_BOX_ARCH
4142

4243
# 下载 jq
@@ -692,7 +693,8 @@ stdout_logfile=/dev/null
692693
#include /etc/nginx/conf.d/*.conf;
693694
694695
server {
695-
listen 127.0.0.1:$START_PORT ssl http2; # sing-box backend
696+
listen 127.0.0.1:$START_PORT ssl ; # sing-box backend
697+
http2 on;
696698
server_name addons.mozilla.org;
697699
698700
ssl_certificate $WORK_DIR/cert/cert.pem;
@@ -702,7 +704,7 @@ stdout_logfile=/dev/null
702704
ssl_stapling off;
703705
ssl_stapling_verify off;"
704706

705-
[ "${VMESS_WS}" = 'true' ] && NGINX_CONF+="
707+
[ "${VLESS_WS}" = 'true' ] && NGINX_CONF+="
706708
# 反代 sing-box vless websocket
707709
location /${UUID}-vless {
708710
if (\$http_upgrade != "websocket") {
@@ -718,7 +720,7 @@ stdout_logfile=/dev/null
718720
proxy_redirect off;
719721
}"
720722

721-
[ "${VLESS_WS}" = 'true' ] && NGINX_CONF+="
723+
[ "${VMESS_WS}" = 'true' ] && NGINX_CONF+="
722724
# 反代 sing-box websocket
723725
location /${UUID}-vmess {
724726
if (\$http_upgrade != "websocket") {
@@ -1154,7 +1156,8 @@ $($WORK_DIR/qrencode https://${ARGO_DOMAIN}/${UUID}/auto)
11541156

11551157
# Sing-box 的最新版本
11561158
update_sing-box() {
1157-
local ONLINE=$(check_latest_sing-box)
1159+
#####local ONLINE=$(check_latest_sing-box)
1160+
local ONLINE='1.11.0-alpha.6'
11581161
local LOCAL=$($WORK_DIR/sing-box version | awk '/version/{print $NF}')
11591162
if [ -n "$ONLINE" ]; then
11601163
if [[ "$ONLINE" != "$LOCAL" ]]; then

sing-box.sh

+4-3
Original file line numberDiff line numberDiff line change
@@ -518,8 +518,8 @@ check_install() {
518518
if [ "${STATUS[0]}" = "$(text 26)" ] && [ ! -s $WORK_DIR/sing-box ]; then
519519
{
520520
local VERSION_LATEST=$(wget --no-check-certificate --tries=2 --timeout=3 -qO- ${GH_PROXY}https://api.github.com/repos/SagerNet/sing-box/releases | awk -F '["v-]' '/tag_name/{print $5}' | sort -Vr | sed -n '1p')
521-
local ONLINE=$(wget --no-check-certificate --tries=2 --timeout=3 -qO- ${GH_PROXY}https://api.github.com/repos/SagerNet/sing-box/releases | awk -F '["v]' -v var="tag_name.*$VERSION_LATEST" '$0 ~ var {print $5; exit}')
522-
ONLINE=${ONLINE:-'1.10.0-beta.11'}
521+
#####local ONLINE=$(wget --no-check-certificate --tries=2 --timeout=3 -qO- ${GH_PROXY}https://api.github.com/repos/SagerNet/sing-box/releases | awk -F '["v]' -v var="tag_name.*$VERSION_LATEST" '$0 ~ var {print $5; exit}')
522+
ONLINE=${ONLINE:-'1.11.0-alpha.6'}
523523
wget --no-check-certificate --continue ${GH_PROXY}https://github.com/SagerNet/sing-box/releases/download/v$ONLINE/sing-box-$ONLINE-linux-$SING_BOX_ARCH.tar.gz -qO- | tar xz -C $TEMP_DIR sing-box-$ONLINE-linux-$SING_BOX_ARCH/sing-box >/dev/null 2>&1
524524
[ -s $TEMP_DIR/sing-box-$ONLINE-linux-$SING_BOX_ARCH/sing-box ] && mv $TEMP_DIR/sing-box-$ONLINE-linux-$SING_BOX_ARCH/sing-box $TEMP_DIR
525525
wget --no-check-certificate --continue -qO $TEMP_DIR/jq ${GH_PROXY}https://github.com/jqlang/jq/releases/download/jq-1.7.1/jq-linux-$JQ_ARCH >/dev/null 2>&1 && chmod +x $TEMP_DIR/jq >/dev/null 2>&1
@@ -2863,7 +2863,8 @@ uninstall() {
28632863
# Sing-box 的最新版本
28642864
version() {
28652865
local VERSION_LATEST=$(wget --no-check-certificate -qO- ${GH_PROXY}https://api.github.com/repos/SagerNet/sing-box/releases | awk -F '["v-]' '/tag_name/{print $5}' | sort -Vr | sed -n '1p')
2866-
local ONLINE=$(wget --no-check-certificate -qO- ${GH_PROXY}https://api.github.com/repos/SagerNet/sing-box/releases | awk -F '["v]' -v var="tag_name.*$VERSION_LATEST" '$0 ~ var {print $5; exit}')
2866+
#####local ONLINE=$(wget --no-check-certificate -qO- ${GH_PROXY}https://api.github.com/repos/SagerNet/sing-box/releases | awk -F '["v]' -v var="tag_name.*$VERSION_LATEST" '$0 ~ var {print $5; exit}')
2867+
local ONLINE='1.11.0-alpha.6'
28672868
local LOCAL=$($WORK_DIR/sing-box version | awk '/version/{print $NF}')
28682869
info "\n $(text 40) "
28692870
[[ -n "$ONLINE" && "$ONLINE" != "$LOCAL" ]] && reading "\n $(text 9) " UPDATE || info " $(text 41) "

0 commit comments

Comments
 (0)