diff options
author | Erik Johnston <lightportal@gmail.com> | 2014-08-24 11:56:55 +0100 |
---|---|---|
committer | Erik Johnston <lightportal@gmail.com> | 2014-08-24 11:56:55 +0100 |
commit | 0c3b4a1f63413c4d3195a14ee4346a6d9cfdf618 (patch) | |
tree | 73d30c9aaa8c99a7f6ba18eb3f23b5521bb3d1b2 /synapse/app/homeserver.py | |
parent | Add a unique constraint on the room hosts table (diff) | |
download | synapse-0c3b4a1f63413c4d3195a14ee4346a6d9cfdf618.tar.xz |
For the content repo, don't just use homeserver.hostname as that might not include the port due to SRV.
Diffstat (limited to 'synapse/app/homeserver.py')
-rwxr-xr-x | synapse/app/homeserver.py | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/synapse/app/homeserver.py b/synapse/app/homeserver.py index 495149466c..40e3561ee5 100755 --- a/synapse/app/homeserver.py +++ b/synapse/app/homeserver.py @@ -37,6 +37,7 @@ import logging import logging.config import sqlite3 import os +import re logger = logging.getLogger(__name__) @@ -255,8 +256,14 @@ def setup(): logger.info("Server hostname: %s", args.host) + if re.search(":[0-9]+$", args.host): + domain_with_port = args.host + else: + domain_with_port = "%s:%s" % (args.host, args.port) + hs = SynapseHomeServer( args.host, + domain_with_port=domain_with_port, upload_dir=os.path.abspath("uploads"), db_name=db_name, ) |