summaryrefslogtreecommitdiff
path: root/src/leap/soledad/server
diff options
context:
space:
mode:
Diffstat (limited to 'src/leap/soledad/server')
-rw-r--r--src/leap/soledad/server/app.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/leap/soledad/server/app.py b/src/leap/soledad/server/app.py
index 725b1383..77d3a1cd 100644
--- a/src/leap/soledad/server/app.py
+++ b/src/leap/soledad/server/app.py
@@ -39,6 +39,12 @@ def _exit(status):
reactor.stop()
+def _log_and_exit(failure):
+ logger.error('Error while starting up server: %r'
+ % failure.getErrorMessage())
+ _exit(20)
+
+
#
# necessary checks
#
@@ -124,6 +130,7 @@ def run(application):
d = check_schema_versions(conf['couch_url'])
d.addCallback(lambda _: create_services(local_port, public_port,
application))
+ d.addErrback(_log_and_exit)
application = service.Application('soledad-server')