Fixed router
This commit is contained in:
parent
8a528e2b4e
commit
3cd53b3dd9
@ -76,16 +76,16 @@ func main () {
|
||||
}
|
||||
|
||||
// be a daemon
|
||||
daemon.ShutdownOnSigint()
|
||||
daemon.ShutdownOnSigint(&manager)
|
||||
pidfile := daemon.PidFile(os.Getenv("HNAKRA_PIDFILE"))
|
||||
if !pidfile.Empty() {
|
||||
err := pidfile.Start()
|
||||
if err != nil { log.Println("!!! could not write pid:", err) }
|
||||
}
|
||||
defer func () {
|
||||
err := pidfile.Close()
|
||||
if err != nil { log.Println("!!! could not delete pidfile:", err) }
|
||||
} ()
|
||||
}
|
||||
|
||||
// run servers
|
||||
err = manager.Run()
|
||||
|
Loading…
Reference in New Issue
Block a user