Node-RED is available on the IBM Cloud platform as one of the boilerplate applications in the catalog.
We also provide a ‘Deploy To IBM Cloud’ enabled repository.
Log in or sign-up for an account at bluemix.net
Navigate to the catalog and search for ‘Node-RED’
This will present you with two options:
Node-RED Starter - a vanilla Node-RED instance
Internet of Things Platform Starter - this gives you everything you need to start quickly using Node-RED with the Watson IoT Platform, including some default flows to show how things work
In both cases you will get:
Click the starter application you want to use, give it a name and click create.
A couple of minutes later, you’ll be able to access your instance of Node-RED at
To start customising your instance of Node-RED, you can either download the application locally or you can enable the Continuous Delivery integration option via your application’s IBM Cloud dashboard page. That will create a git repository on either GitHub or IBM DevOps services, from where you can customize your Node-RED, save the changes and automatically update the application in IBM Cloud.
When you first ran the Node-RED instance you were presented with some options to secure the editor. To change those options, you can set some environment variables from either the IBM Cloud console or the cf command-line
NODE_RED_USERNAME- the username to secure the editor with
NODE_RED_PASSWORD- the password to secure the editor with
NODE_RED_GUEST_ACCESS- set to true to allow anonymous users to have read-only access to the editor
You can add nodes from within the editor. Select the
manage palette option from
the dropdown menu within the editor.
Alternatively, you can edit the application’s
package.json file and
add the required node modules in the
dependencies section. The format is:
"node-red-node-package-name":"x.x.x" Where x.x.x is the desired version number.
The application’s package.json is setup to grab the latest stable release of Node-RED. To trigger an upgrade following a new release being made available:
Per default IBM Cloud maintains a cache directory per node application, to store resolved dependencies so they are not downloaded and installed every time. For updates this cache should be disabled. Set the NODE_MODULES_CACHE environment variable to false. You can either do this on your application’s IBM Cloud console page (Runtime -> Environment Variables), or by using the cf command-line:
cf set-env [APPLICATION_NAME] NODE_MODULES_CACHE false
Trigger a restage of your application. This cannot be done using the IBM Cloud console, so the cf command-line should be used:
cf restage [APPLICATION_NAME]
If you are upgrade to Node-RED 0.20 or later, you must ensure your application is running on Node.js 8 or later. To do that, edit you application
package.json file - see below for how to edit the file. Update the
engines property to
8.x if it is not currently set to that.
In order to edit the file, you must enable the Continuous Delivery integration option via your application’s IBM Cloud dashboard page. That will create a git repository on either GitHub or IBM DevOps services, from where you can edit the file, save the changes and automatically update the application in IBM Cloud.
The landing page of your instance is provided by static content with the application.
This can be replaced with whatever content you want in the
If you want to remove the static web content and serve the flow editor from the
root path, delete the
httpAdminRoot entries in the
The Deploy To Bluemix enabled repository lets you create your own customised Node-RED application that can then be deployed to IBM Cloud with a couple clicks.
You can try it out now by clicking here:
When you click the button, you are taken to IBM Cloud where you get a pick a name for your application at which point the platform takes over, grabs the code from this repository and deploys it.
It will automatically create an instance of the Cloudant service, call it
sample-node-red-cloudantNoSQLDB and bind it to your application. This is where your
Node-RED instance will store its data. If you deploy multiple instances of
Node-RED from this repository, they will share the one Cloudant instance.
It includes a set of default flows that are automatically deployed the first time Node-RED runs.
The repository is there to be cloned, modified and re-used to allow anyone to create their own Node-RED based application that can be quickly deployed to IBM Cloud.
The default flows are stored in the
defaults directory in the file called
The web content you get when you go to the application’s URL is stored under the
Additional nodes can be added to the
package.json file and all other Node-RED
configuration settings can be set in
If you do clone the repository, make sure you update the
README.md file to point
Deploy to IBM Cloud button at your repository.
If you want to change the name of the Cloudant instance that gets created, the memory
allocated to the application or other deploy-time options, have a look in