mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-07 20:31:06 -05:00
Merge pull request #48 from sharelatex/bg-fix-close-app-shutdown
fix beginShutdown to use server.close()
This commit is contained in:
commit
74f26a5fa9
1 changed files with 2 additions and 2 deletions
|
@ -117,7 +117,7 @@ beginShutdown = () ->
|
||||||
process.exit 1
|
process.exit 1
|
||||||
, 120*1000
|
, 120*1000
|
||||||
killTimer.unref?() # prevent timer from keeping process alive
|
killTimer.unref?() # prevent timer from keeping process alive
|
||||||
app.close () ->
|
server.close () ->
|
||||||
logger.log "closed all connections"
|
logger.log "closed all connections"
|
||||||
Metrics.close()
|
Metrics.close()
|
||||||
process.disconnect?()
|
process.disconnect?()
|
||||||
|
@ -128,7 +128,7 @@ port = settings.internal.filestore.port or 3009
|
||||||
host = "0.0.0.0"
|
host = "0.0.0.0"
|
||||||
|
|
||||||
if !module.parent # Called directly
|
if !module.parent # Called directly
|
||||||
app.listen port, host, (error) ->
|
server = app.listen port, host, (error) ->
|
||||||
logger.info "Filestore starting up, listening on #{host}:#{port}"
|
logger.info "Filestore starting up, listening on #{host}:#{port}"
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue