mirror of
https://github.com/Dichgrem/singbox-example.git
synced 2026-02-05 07:51:55 -05:00
Compare commits
1 Commits
2e1eefb0b7
...
main
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
edb8d0ff85 |
@@ -1,7 +1,7 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
# install_singbox.sh
|
# install_singbox.sh
|
||||||
# 版本号
|
# 版本号
|
||||||
SCRIPT_VERSION="1.12.15"
|
SCRIPT_VERSION="1.12.17"
|
||||||
set -euo pipefail
|
set -euo pipefail
|
||||||
|
|
||||||
# 颜色定义
|
# 颜色定义
|
||||||
@@ -444,10 +444,10 @@ update_singbox() {
|
|||||||
|
|
||||||
NEW_VER=$($BIN_NAME version 2>/dev/null | head -n1 | awk '{print $NF}')
|
NEW_VER=$($BIN_NAME version 2>/dev/null | head -n1 | awk '{print $NF}')
|
||||||
echo "✅ Sing-box 已升级到版本:$NEW_VER"
|
echo "✅ Sing-box 已升级到版本:$NEW_VER"
|
||||||
echo "🔁 正在重启服务..."
|
echo "🔁 正在重载 systemd 并重启服务..."
|
||||||
|
|
||||||
if systemctl restart sing-box.service; then
|
|
||||||
systemctl daemon-reload
|
systemctl daemon-reload
|
||||||
|
if systemctl restart sing-box.service; then
|
||||||
echo "✅ 服务已重启。"
|
echo "✅ 服务已重启。"
|
||||||
else
|
else
|
||||||
echo "⚠️ 服务重启失败,请手动检查。"
|
echo "⚠️ 服务重启失败,请手动检查。"
|
||||||
|
|||||||
Reference in New Issue
Block a user