diff options
author | Kegan Dougal <kegan@matrix.org> | 2014-08-26 15:06:24 +0100 |
---|---|---|
committer | Kegan Dougal <kegan@matrix.org> | 2014-08-26 15:06:24 +0100 |
commit | b07bc9bdbdcf70755c1075e204e36e8ebd44e57d (patch) | |
tree | d7943508bd16f2c4e2d81590ad1edcc1ff1d4d5c /synapse/app/homeserver.py | |
parent | Merge branch 'client_server_url_rename' into develop (diff) | |
parent | Merge branch 'develop' of github.com:matrix-org/synapse into client_server_ur... (diff) | |
download | synapse-b07bc9bdbdcf70755c1075e204e36e8ebd44e57d.tar.xz |
Merge branch 'client_server_url_rename' into develop
Diffstat (limited to 'synapse/app/homeserver.py')
-rwxr-xr-x | synapse/app/homeserver.py | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/synapse/app/homeserver.py b/synapse/app/homeserver.py index 40e3561ee5..f210d26629 100755 --- a/synapse/app/homeserver.py +++ b/synapse/app/homeserver.py @@ -31,6 +31,7 @@ from synapse.api.urls import ( ) from daemonize import Daemonize +import twisted.manhole.telnet import argparse import logging @@ -238,6 +239,8 @@ def setup(): default="hs.pid") parser.add_argument("-W", "--webclient", dest="webclient", default=True, action="store_false", help="Don't host a web client.") + parser.add_argument("--manhole", dest="manhole", type=int, default=None, + help="Turn on the twisted telnet manhole service.") args = parser.parse_args() verbosity = int(args.verbose) if args.verbose else None @@ -281,6 +284,13 @@ def setup(): hs.build_db_pool() + if args.manhole: + f = twisted.manhole.telnet.ShellFactory() + f.username = "matrix" + f.password = "rabbithole" + f.namespace['hs'] = hs + reactor.listenTCP(args.manhole, f, interface='127.0.0.1') + if args.daemonize: daemon = Daemonize( app="synapse-homeserver", |