summary refs log tree commit diff
path: root/synapse/app/federation_reader.py
diff options
context:
space:
mode:
authorErik Johnston <erikj@jki.re>2017-01-13 13:02:59 +0000
committerGitHub <noreply@github.com>2017-01-13 13:02:59 +0000
commit641ccdbb14be249c96f11c9d461c1429a6fc86a9 (patch)
tree361c50b0a3319280b8a0bde50dc00f264db36e10 /synapse/app/federation_reader.py
parentREADME.rst: fix formatting (diff)
parentPop bind_address (diff)
downloadsynapse-641ccdbb14be249c96f11c9d461c1429a6fc86a9.tar.xz
Merge pull request #1795 from matrix-org/erikj/port_defaults
Restore default bind address
Diffstat (limited to 'synapse/app/federation_reader.py')
-rw-r--r--synapse/app/federation_reader.py12
1 files changed, 2 insertions, 10 deletions
diff --git a/synapse/app/federation_reader.py b/synapse/app/federation_reader.py
index c6810b83db..90a4816753 100644
--- a/synapse/app/federation_reader.py
+++ b/synapse/app/federation_reader.py
@@ -86,8 +86,7 @@ class FederationReaderServer(HomeServer):
 
     def _listen_http(self, listener_config):
         port = listener_config["port"]
-        bind_address = listener_config.get("bind_address", None)
-        bind_addresses = listener_config.get("bind_addresses", [])
+        bind_addresses = listener_config["bind_addresses"]
         site_tag = listener_config.get("tag", port)
         resources = {}
         for res in listener_config["resources"]:
@@ -101,9 +100,6 @@ class FederationReaderServer(HomeServer):
 
         root_resource = create_resource_tree(resources, Resource())
 
-        if bind_address is not None:
-            bind_addresses.append(bind_address)
-
         for address in bind_addresses:
             reactor.listenTCP(
                 port,
@@ -123,11 +119,7 @@ class FederationReaderServer(HomeServer):
             if listener["type"] == "http":
                 self._listen_http(listener)
             elif listener["type"] == "manhole":
-                bind_address = listener.get("bind_address", None)
-                bind_addresses = listener.get("bind_addresses", [])
-
-                if bind_address is not None:
-                    bind_addresses.append(bind_address)
+                bind_addresses = listener["bind_addresses"]
 
                 for address in bind_addresses:
                     reactor.listenTCP(