diff options
author | Paul "LeoNerd" Evans <paul@matrix.org> | 2014-09-10 16:16:24 +0100 |
---|---|---|
committer | Paul "LeoNerd" Evans <paul@matrix.org> | 2014-09-10 16:16:24 +0100 |
commit | 2faffc52eed70df7cf1adc021633f4a427917c90 (patch) | |
tree | ea2da9ef011804d5a9287c0d62a7bd72486b7cdb | |
parent | No need for a tiny run() function any more, just use reactor.run() directly (diff) | |
download | synapse-2faffc52eed70df7cf1adc021633f4a427917c90.tar.xz |
Make sure not to open our TCP ports until /after/ the DB is nicely prepared ready for use
-rwxr-xr-x | synapse/app/homeserver.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/synapse/app/homeserver.py b/synapse/app/homeserver.py index e9a6321020..e6377e3060 100755 --- a/synapse/app/homeserver.py +++ b/synapse/app/homeserver.py @@ -207,7 +207,6 @@ def setup(): web_client=config.webclient, redirect_root_to_web_client=True, ) - hs.start_listening(config.bind_port, config.unsecure_port) prepare_database(hs.get_db_name()) @@ -220,6 +219,8 @@ def setup(): f.namespace['hs'] = hs reactor.listenTCP(config.manhole, f, interface='127.0.0.1') + hs.start_listening(config.bind_port, config.unsecure_port) + if config.daemonize: print config.pid_file daemon = Daemonize( |