summary refs log tree commit diff
path: root/synapse/app/homeserver.py
diff options
context:
space:
mode:
authorEmmanuel ROHEE <erohee@amdocs.com>2014-08-25 11:13:54 +0200
committerEmmanuel ROHEE <erohee@amdocs.com>2014-08-25 11:13:54 +0200
commit1bd380c816493ffdd2c2a7a6463b1ef48c1bfcab (patch)
tree92d4bb31a1372239e317f8672d6b80e59b709523 /synapse/app/homeserver.py
parentOops. Removed my NetBeans private folders (diff)
parentFor the content repo, don't just use homeserver.hostname as that might not in... (diff)
downloadsynapse-1bd380c816493ffdd2c2a7a6463b1ef48c1bfcab.tar.xz
Merge remote-tracking branch 'origin/hotfixes-0.0.1' into develop
Diffstat (limited to 'synapse/app/homeserver.py')
-rwxr-xr-xsynapse/app/homeserver.py7
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,
     )