mirror of
https://github.com/ehang-io/nps.git
synced 2025-07-05 06:40:43 +00:00
Client run bug
This commit is contained in:
parent
006ddbc871
commit
00a4a33c5f
@ -163,6 +163,7 @@ re:
|
|||||||
}
|
}
|
||||||
|
|
||||||
c.Close()
|
c.Close()
|
||||||
|
logs.Notice("Temporary access login key ", vkey)
|
||||||
NewRPClient(cnf.CommonConfig.Server, vkey, cnf.CommonConfig.Tp, cnf.CommonConfig.ProxyUrl, cnf).Start()
|
NewRPClient(cnf.CommonConfig.Server, vkey, cnf.CommonConfig.Tp, cnf.CommonConfig.ProxyUrl, cnf).Start()
|
||||||
CloseLocalServer()
|
CloseLocalServer()
|
||||||
goto re
|
goto re
|
||||||
|
@ -24,21 +24,25 @@ func InitDaemon(f string, runPath string, pidPath string) {
|
|||||||
switch os.Args[1] {
|
switch os.Args[1] {
|
||||||
case "start":
|
case "start":
|
||||||
start(args, f, pidPath, runPath)
|
start(args, f, pidPath, runPath)
|
||||||
|
os.Exit(0)
|
||||||
case "stop":
|
case "stop":
|
||||||
stop(f, args[0], pidPath)
|
stop(f, args[0], pidPath)
|
||||||
|
os.Exit(0)
|
||||||
case "restart":
|
case "restart":
|
||||||
stop(f, args[0], pidPath)
|
stop(f, args[0], pidPath)
|
||||||
start(args, f, pidPath, runPath)
|
start(args, f, pidPath, runPath)
|
||||||
|
os.Exit(0)
|
||||||
case "status":
|
case "status":
|
||||||
if status(f, pidPath) {
|
if status(f, pidPath) {
|
||||||
log.Printf("%s is running", f)
|
log.Printf("%s is running", f)
|
||||||
} else {
|
} else {
|
||||||
log.Printf("%s is not running", f)
|
log.Printf("%s is not running", f)
|
||||||
}
|
}
|
||||||
|
os.Exit(0)
|
||||||
case "reload":
|
case "reload":
|
||||||
reload(f, pidPath)
|
reload(f, pidPath)
|
||||||
|
os.Exit(0)
|
||||||
}
|
}
|
||||||
os.Exit(0)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
func reload(f string, pidPath string) {
|
func reload(f string, pidPath string) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user