Base url: Fix external port different from internal port (#4990)
* Base url: Fix external port different from internal port * Add base_url example to new config
This commit is contained in:
1 parent
744d00a36e
commit
ed0d14c902
4 files changed
+23
-9
No files matched your search
@@ -161,13 +161,15 @@ def async_setup(hass, config):
|
||||
host = conf.get(CONF_BASE_URL)
|
||||
|
||||
if host:
|
||||
pass
|
||||
port = None
|
||||
elif server_host != DEFAULT_SERVER_HOST:
|
||||
host = server_host
|
||||
port = server_port
|
||||
else:
|
||||
host = hass_util.get_local_ip()
|
||||
port = server_port
|
||||
|
||||
hass.config.api = rem.API(host, api_password, server_port,
|
||||
hass.config.api = rem.API(host, api_password, port,
|
||||
ssl_certificate is not None)
|
||||
|
||||
return True
|
||||
|
||||
Reference in new issue
Block a user