ct-Open-Source / ct-Smart-Home

A ready-to-use Node-RED setup for home automation
https://ct.de/smarthome
GNU General Public License v2.0
165 stars 40 forks source link

Frontend zigbee2mqtt at port 1881 not working #42

Closed Leinetaler closed 3 years ago

Leinetaler commented 3 years ago

Hi, i pulled the actual master (with docker-compose.yml version 3.6) as i´m keen to use the zigbee2mqtt frontend instead of the zigbee2mqttAsisstent.

so, port 1881 is defined in start.sh and in docker-compose.yml but it is not working.

Áctual i can´t find a reason for that (or any log entry hint). Only thing i found is, that the network_mode setting "host" ist back in docker-compose-yml.

Any suggestion for next analyse - step would be very appreciated :-)

best regards

Leinetaler commented 3 years ago

1.) run the start.sh update replies with one error about "orphan" zigbeeadmin container (see console output below)

2.) the zigbee2mqtt assistent is still running on port 8880

3.) The zigbee2mqtt frontend only starts by adding the frontend parameter to zigbeeconfiguration.yaml, but it does not load data.

console output on update:

pi@raspberrypi:~/Downloads/ct-Smart-Home-master $ ./start.sh stop 🛑 Stopping all containers Stopping ct-smart-home-master_nodered_1 ... done Stopping ct-smart-home-master_zigbee_1 ... done Stopping ct-smart-home-master_mqtt_1 ... done pi@raspberrypi:~/Downloads/ct-Smart-Home-master $ ./start.sh update ☠️ Shutting down all running containers and removing them. WARNING: Found orphan containers (ct-smart-home-master_zigbeeadmin_1) for this project. If you removed or renamed this service in your compose file, you can run this command with the --remove-orphans flag to clean it up. Removing ct-smart-home-master_nodered_1 ... done Removing ct-smart-home-master_zigbee_1 ... done Removing ct-smart-home-master_mqtt_1 ... done Removing network ct-smart-home-master_default ERROR: error while removing network: network ct-smart-home-master_default id fbe084b6ca8a65152b6cb210a6e29ae974713b5d093978c0a63c72ffc8b23f6b has active endpoints ⚠️ Updating failed. Please check the repository on GitHub. ⬇️ Pulling latest release via git. fatal: Kein Git-Repository (oder irgendeines der Elternverzeichnisse): .git fatal: Kein Git-Repository (oder irgendeines der Elternverzeichnisse): .git fatal: Kein Git-Repository (oder irgendeines der Elternverzeichnisse): .git fatal: Kein Git-Repository (oder irgendeines der Elternverzeichnisse): .git ⚠️ Updating failed. Please check the repository on GitHub. ⬇️ Pulling docker images. Pulling mqtt ... done Pulling nodered ... done Pulling zigbee ... done 🏃 Starting the containers WARNING: Found orphan containers (ct-smart-home-master_zigbeeadmin_1) for this project. If you removed or renamed this service in your compose file, you can run this command with the --remove-orphans flag to clean it up. Creating ct-smart-home-master_zigbee_1 ... done Creating ct-smart-home-master_mqtt_1 ... done Creating ct-smart-home-master_nodered_1 ... done ⚠️ After you made yourself familiar with the setup, it's strongly suggested to secure the services. Read the "Security" section in the README! pi@raspberrypi:~/Downloads/ct-Smart-Home-master $

merlinschumacher commented 3 years ago

If you have orphan containers, try docker-compose down --remove-orphans followed by ./start.sh start.

I'll add that to the start script to avoid future issues.

merlinschumacher commented 3 years ago

The network_mode: host is still present. Removing the port definition was the correct way. network_mode:host activates a mode, where Node-Red can open any port on the host device. This is the only way to get the HomeKit integration to work.

Leinetaler commented 3 years ago

thanks for your patience and explanation. Result of new master is now:

1.) update now runs without error. 2.) Zigbee2mqttAsisstent is gone. 3.) zigbee2mqttfrontend appears on :1881 4.) Frontend error: Loading devices takes too long time. Consider reading documentation (which is linked to doku#frontend) 5.) zigbee2mqtt log shows only this expected warning:

warn 2020-12-15 14:20:13:permit_joinset totruein configuration.yaml. warn 2020-12-15 14:20:13: Allowing new devices to join. warn 2020-12-15 14:20:13: Setpermit_jointofalseonce you joined all devices. info 2020-12-15 14:20:13: Zigbee: allowing new devices to join. info 2020-12-15 14:20:13: Started frontend on port 0.0.0.0:1881 info 2020-12-15 14:20:13: Connecting to MQTT server at mqtt://mqtt info 2020-12-15 14:20:13: Connected to MQTT server

summery: update works - only frontend is not loading existing data

Leinetaler commented 3 years ago

Seems to be related to a file path, as from loaded frontend also the logs are not accessible.

Leinetaler commented 3 years ago

Seems this project is still under development. so, i decidet to implement the apps direct on raspi as a service without docker.

Usage of the install instructions of mosquitto, zigbee2mqtt and node-red gives (me) simply more insights of the system = controll = success.

but, thank you for the interesting project and raspi/node-red incubation :-)