Home Assistant Community Add-on: Node-RED

:tada: Released v0.2.0

Full Changelog

Added

  • Added greenkeeper to keep all packages updated at all times
  • Adds note about GPIO warning messages
  • Adds access to the share folder

Fixed

  • Fixes incorrect configuration variable in README
  • Sets hadolint fixed to v1.6.6

Changed

  • Updated node-red-contrib-bigtimer to v1.9.2
  • Upgrades base image to v1.4.2
  • Rewrites GitLab CI
  • Upgrades base image in GitLab CI to 1.4.2

Thank you!!! I was about to try my third attempt to get SSL working with NotoriousBDG’s addon, until I found your version. Just installed it, but so far so good–I’m able to see all my Home Assistant sensors and devices. I’ll buy you a coffee soon!

They work as any other entity/device in Hass.io. You just need to figure out the entity id and program it accordingly.

Check this out!

Cheers

How do I use the credential secret option ? A the moment, my home assistant API key is plain text within the flow .

Thank you for the update, but I have 2 problems.

First with the share folder. No node red folder appears in the share folder.
Also when I try to generate an SSH key for Git, nothing happens.

As a result there is no way someone can back up all the flows.

This is correct. The share folder is accessible by the add-on, but not used by the add-on.
E.g., if you have a camera posting images in the shares folder, you are now able to access the using your flows (or any other case).

The actual configuration / flows of Node-RED are stored in the /config/node-red/ folder.

I’m not sure what this has to do with the Node-RED add-on.

Actually, you do. Since the configuration is stored in /config/node-red you have several options getting access to them / backup them:

  • Using Hass.io Snapshots
  • Using one of the SSH add-ons (e.g., via SFTP)
  • Using the FTP via the FTP add-on
  • Using the Samba / Windows file sharing using the Samba add-on
  • … and many more…

So, since this add-on uses the /config location as its base, it opens up possibilities to access them and backup them using anything you like.

1 Like

Thank you for clarifying that. I was expecting it to be in the share folder, I didn’t look in the config folder :slight_smile:

Are git and ssh-keygen command line tools available? Because node red projects relies on having them.

Hi,
when adding “credential_secret” - is it supposed to disappear from the setting file after saving?
Have tried both using “credential_secret” and “credentialSecret” - added while the addon is stopped, saved after changing and then restartet the addon - and then the change dissapears…
Shouldn’t it stay there?
Thanks in advance,
Chr.

Hi, since today I’m having this error

23 Jun 15:31:26 - [error] [server-state-changed:Security] TypeError: Cannot read property ‘state’ of null

on almost all my devices in node red. Automations seems to work. I have updated Hassio to 0.72 and that has started. Can I have any help please. BTW. I’m quite new to Hassio.

Thank You

I need help repairing my node-red install. I started with Notorious-BDG version and add-on was working correctly. I then saw this released and wanted to use this one before I created any real flows. I uninstalled BDG version and added this. My mind draws a blank as to my next steps but lets just say I managed to mess up the HA integration (think I was trying to configure like BDG version - which wasn’t necessary).
I then decided to re-install the addon which didn’t help. Reading a previous post, I uninstalled the addon, deleted the node-red folders from share and config (hadn’t removed BDG folder), which seems to have removed the files but there’s a couple of empty folders that won’t delete, rebooted rpi3, and tried installing addon again. I have a credential_secret, user and SSL configured.

Now I get the following from the log window of the addon:

[email protected] start /opt
node $NODE_OPTIONS node_modules/node-red/red.js “–settings” “/etc/node-red/config.js”
Error loading settings file: /etc/node-red/config.js
Error: Cannot find module ‘/config/node-red/settings.js’

It seems to not have replaced the folder contents with fresh files as config/node-red still has a few empty sub-folders.
How do I clear out the addon completely so I can start fresh?

secondary question: once running, how do I get rid of the annoying git project message… I don’t want to store any files publicly in git or set up my own git server thanks. Happy as long as my flows are saved as part of a hassio snapshot.

running Hassio 0.72.0 and node-red 0.2.0.

Thanks.

:tada: Release v0.2.1

Full Changelog

Added

  • Maps all UART/Serial devices to add-on
1 Like
  • Stop the add-on
  • Delete the node-red folder in the /config directory
  • Start add-on.

This would give you a fresh start.

Thanks @frenck for the steer along the right lines. The stubborn empty folder structure was causing the issue. I had to SSH into the Pi then use the following to delete the folders:
cd /share [edit: meant cd /config]
rm -r node-red

Starting the web UI, it wouldn’t accept my username/PW until I restarted HA.

Do you have a solution for the project pop-up screen? Is there a way to add a “don’t ask me again unless I click an option in the settings”?

That is odd, since this add-on does not use that folder. There are a couple of other node-red add-ons out there that do, so maybe you are in the wrong topic.

Yes, reverse this: Projects : Node-RED

I’m getting an error message when I start the add-on after configuring the settings as specified in the github install instructions and hitting save. The error message in the add-on log is, "Error: Cannot find module ‘bcryptjs’. I’ve tried installing bcryptjs via the “npm_packages” and “system_packages” configuration parameters, but haven’t been successful with a variety of package names. I’m running the latest version of hassio. Will someone please let me know how to properly install the ‘bcryptjs’ module?

That does not sound right, please provide some debug logs and hardware information (and maybe, just create a GitHub issue…)

Ah… I deleted the /config/node-red folder as well as the /share/node-red. I realise the share one is from notoriousBDG version. Post corrected.

Projects feature popup now successfully disabled. :slight_smile:

In some of the other add ons of Node Red there is a timestamp node which makes it possible to trigger the flow manually when testing. That is missing here, but is there another node that does the same?

I also see this same problem. Projects were added in 0.18 and it uses git, with optional remotes, for version control built directly into node-red.
It would use SSH keys from here: /config/node-red/projects/.sshkeys/
But as mentioned it cannot generate them - probably as ssh-keygen is not in this container.
Also when you try to connect to the git remote from the history tab it cannot - probably no git.

Are you looking for the Inject node? That allows you to inject timestamps etc.