Can I install additional nodes in Node-RED myself?

Q

Can I install additional nodes in Node-RED myself?

A

To install additional nodes call Manage Palette from the Node-RED menu (top right), and then select the install tab in the palette. There you can search for additional nodes to be installed and enable or disable existing nodes.

To resolve packages by name and version the installer talks to a registry website that is located at https://registry.npmjs.org/. So during the process the gateway needs internet connectivity and TCP/IP access to this npm-registry that holds all installable nodes in a database as described here. The nodes themselves are usually located at https://www.npmjs.com/package/ from where they are installed.

Make sure your gateway has access to these internet locations. This needs a correct network settings in the Edge Gateway's Control Panel as the picture below shows. Most important is having at least one DNS server entered to resolve the registry name to an IP address.

To check if Node-RED has access to the internet use the following simple code, that sends a https:// request to the registry and returns the content to the debug window:

Here is the code you can import to your Node-RED to make connection checks yourself:

[{"id":"be2434a4.2fdc18","type":"tab","label":"Flow 1","disabled":false,"info":""},{"id":"b20d6769.6e56c8","type":"inject","z":"be2434a4.2fdc18","name":"Read Registry","topic":"","payload":"","payloadType":"date","repeat":"","crontab":"","once":false,"x":150,"y":80,"wires":[["48f00962.5c46e8"]]},{"id":"48f00962.5c46e8","type":"http request","z":"be2434a4.2fdc18","name":"https://registry.npmjs.org/","method":"GET","ret":"txt","url":"https://registry.npmjs.org/","tls":"","x":241,"y":172,"wires":[["70a99816.42b2c8"]]},{"id":"2389e2b0.d5cafe","type":"debug","z":"be2434a4.2fdc18","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","x":510,"y":77,"wires":[]},{"id":"70a99816.42b2c8","type":"json","z":"be2434a4.2fdc18","name":"","property":"payload","action":"","pretty":false,"x":433,"y":171,"wires":[["2389e2b0.d5cafe"]]}]

After you checked the access you need to know the following:

a.) You can install all those nodes not needing a onboard compilation process through a GNU compiler.

b.) You cannot install nodes needing a compilation process. Some available nodes need a compilation process of hardware specific "C" code to get installed. Because of security reasons Edge Gateways have no GNU compiler installed and all those nodes cannot be installed through the Manage Palette service.

Nodes that need an additional compilation process can only be compiled by Hilscher and provided as installable package on demand as a service. Such a package can be installed using the package manager in the Edge Gateway Manager along with the provided *.deb installation file. Those files are signed with a special key to prove the software is genuine.

Only Hilscher is able to generate *.deb files with valid signature to be accepted by the Edge Gateways' package manager. Since each Edge gateway has its own signature Hilscher has to provide multiple files for multiple targets.