danielwelch / hassio-zigbee2mqtt

Hass.io add-on for zigbee2mqtt
Apache License 2.0
565 stars 190 forks source link

Troubles with addon package - frontend port, unable to set devices in config #514

Closed mhrynovets closed 3 years ago

mhrynovets commented 3 years ago

zigbee2mqtt add-on version: 1.17.0.1

Operating environment (HassOS, Virtual Machine, Device/platform running Home Assistant): HA-supervised 2021.1.1 on RPI2

Description of problem: I tried to find define a friendly_name for zigbee devices. Manuals say, that I have to place a block in section 'devices' into file configuration.yaml. I'm a newbie with HA and searched, which one of config file it should be (for HA and z2m they have same name configuration.yaml). Pasting this section in HA config was faulty (no integration named 'devices') - I found, that config for z2m have such section. But my tries to paste block with friendly_name to this section was faulty too!

I found, that z2m has a frontend, where I can set friendly_name - but default port 8099 and the another one 8080, that i used in manuals - are not responding (404).

Netstat on rpi said, that 8099 and 8080 are not listening. But is listening port 8485, that by description is "Socat tcp-listen port" (which is disabled).

After configuration frontend to port 8485 - it becomes accessible.

It seems, that there are not enough ports proxied from z2m docker image to host and schema for config is to rigid and blocks to put a valid data.

Your entire configuration from the frontend (with sensitive fields redacted):

  "ports": {
    "8485/tcp": 8485
  },
  "ports_description": {
    "8485/tcp": "Socat tcp-listen port"
  },
"devices": "str?",
ciotlosm commented 3 years ago

You should use most of the default settings. The frontend port is custom set to 8099 for easier usage using ingress. If you want to set friendly names you can use either the frontend or the file on the disk using some sort of file editor.

You can use terminal add-on or file editor add-on and navigate to /share/zigbee2mqtt/devices.yaml or /config/zigbee2mqtt/devices.yaml depending on your configuration and change what you need.