forked from forgejo/forgejo
Graceful fixes (#8645)
* Only attempt to kill parent once * Apply suggestions from code review Co-Authored-By: guillep2k <18600385+guillep2k@users.noreply.github.com> * Add waitgroup for running servers
This commit is contained in:
parent
7d1a7c05db
commit
f067e12859
5 changed files with 35 additions and 7 deletions
|
@ -48,7 +48,7 @@ func (srv *Server) handleSignals() {
|
|||
if setting.GracefulRestartable {
|
||||
log.Info("PID: %d. Received SIGHUP. Forking...", pid)
|
||||
err := srv.fork()
|
||||
if err != nil {
|
||||
if err != nil && err.Error() != "another process already forked. Ignoring this one" {
|
||||
log.Error("Error whilst forking from PID: %d : %v", pid, err)
|
||||
}
|
||||
} else {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue