From b023b123642b422f7d42655ad3082febeb3ea713 Mon Sep 17 00:00:00 2001 From: Jrohy Date: Wed, 30 Jun 2021 11:28:22 +0800 Subject: [PATCH] =?UTF-8?q?=E9=87=8D=E5=90=AF/=E5=90=AF=E5=8A=A8trojan?= =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E7=AB=AF=E5=8F=A3=E5=BC=80=E6=94=BE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- trojan/trojan.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/trojan/trojan.go b/trojan/trojan.go index 22048714..1c66804b 100644 --- a/trojan/trojan.go +++ b/trojan/trojan.go @@ -49,6 +49,7 @@ func ControllMenu() { // Restart 重启trojan func Restart() { + util.OpenPort(core.GetConfig().LocalPort) if err := util.ExecCommand("systemctl restart trojan"); err != nil { fmt.Println(util.Red("重启trojan失败!")) } else { @@ -58,6 +59,7 @@ func Restart() { // Start 启动trojan func Start() { + util.OpenPort(core.GetConfig().LocalPort) if err := util.ExecCommand("systemctl start trojan"); err != nil { fmt.Println(util.Red("启动trojan失败!")) } else {