Node-Red and trigger from home-assistant.log

Because my doorbell send “group on” and not ON/OFF im unable to trigger something happeng in node red without using som workaround.

My current setup is:
1: Tail NODE that tails /config/home-assistant.log
2: A String NODE that searches for: "contains = xxxxxxxx (the id of my doorbell) and “tostring”
3: A FUNCTION node that “if true = msg.payload (service: turn_on)” and “if false = msg.payload (service: turn_off)”
4: Sending this to (in this case a switch thats turns on when the doorbell is pressed)

My question.
Im a total NOOB regarding node-red. Are there any better way to do this instead of tailing the log-file and searching for a pattern?


1 Like

Does the event show up in the events all node?

No. I created the “Events All Node” and pressed the button but nothing was shown in the debug node.