HTTP integration and server_port setting

I am trying to configure 0110.0 as a test environment.

I am using a docker install of core HA

After setting up a new config folder and setting up the docker naturally the (default) port is 8123.

I understood that I can use the HTTP integration to set the default port to another port (of my choice) however once I edit config.yaml to do that I can no longer connect to HA on either the 8123 port or my new choice of 8889.

Here is my edited config.yaml:

http:
  server_port: 8889
# Configure a default setup of Home Assistant (frontend, api, etc)
default_config:

# Text to speech
tts:
  - platform: google_translate

group: !include groups.yaml
automation: !include automations.yaml
script: !include scripts.yaml
scene: !include scenes.yaml

Anyone have a clue what I may be doing wrong or is what I’m attempting not possible?

Cheers!

Have you rebooted your machine since setting the setting?

Any errors in the log?

I rebooted but couldn’t get to the UI

When I read the log file there is just one entry:

2020-05-20 10:15:34 WARNING (MainThread) [homeassistant.components.http.ban] Login attempt or request with invalid authentication from 192.168.x.xx

Restarted the container that is?
EDIT: Small progress

Checked log again after adjusting config to:

# Configure a default setup of Home Assistant (frontend, api, etc)
config:

http:
  server_port: 8889

# Text to speech
tts:
  - platform: google_translate

group: !include groups.yaml
automation: !include automations.yaml
script: !include scripts.yaml
scene: !include scenes.yaml

Log:

2020-05-20 10:45:31 ERROR (MainThread) [homeassistant.components.http] Failed to create HTTP server at port 8889: [Errno 98] error while attempting to bind on address (‘0.0.0.0’, 8889): address in use

So rejigged the config to:

# Configure a default setup of Home Assistant (frontend, api, etc)
config:

http:
  server_port: 8870

# Text to speech
tts:
  - platform: google_translate

group: !include groups.yaml
automation: !include automations.yaml
script: !include scripts.yaml
scene: !include scenes.yaml

So the log does not change but I get:

404: Not Found (in my browser)

Ok…got it now:

# Configure a default setup of Home Assistant (frontend, api, etc)
default_config:

http:
  server_port: 8125

# Text to speech
tts:
  - platform: google_translate

group: !include groups.yaml
automation: !include automations.yaml
script: !include scripts.yaml
scene: !include scenes.yaml

Found an unused port and set back to “default_config:”

2 Likes

This is a very old topic, but I want to ask too (especially that it’s solved), what changes will the users feel if integrating HTTP in your smart home, other than the changed port here (to 8125)?