How to install Node-RED and survive

by | Home assistant, Smart Hubs

This is a quick guide how to install Node-RED for your Home Assistant and survive

If this is all new to you, Home Assistant is one of the most flexible and sophisticated open-source smart home platform, and Node-RED is a visual programming tool making rule creation a walk in the park (ish).

Pre-Requisites 

  • Install a Home Assistant – Well, the first thing you need to do make sure that you have Home Assistant. If you don’t and keen to try, it would take you 10 minutes using this guide. If you are new to Home Assistant or not the most experienced user, I suggest to install Hass.io. It is a simpler flavour of Home Assistant, which manages updates and add-ons in the easy way.
  • Buy or integrate couple of devices to play way. If you need some inspiration, please use our suggestions on the $250 kit for the smart home beginners, allowing you to create rules and experiment with the seven devices included.

Installing Node-RED

Once you have Home Assistant running, you need to install the a Node-Red. The way to do it mainly depend on the version of the Home Assistant you decided to install. 

A) Installing Node-RED for Hass.io

This is the simplest way forward. You need to use a great add-on by Frenck (amazing guy) in the community add-on repository.  

  1. Add repository to your Hass.io. It is done on the Hass.io folder, under ADD-ON STORE tab. It would be auto installed for the majority of users, but just paste the url below if it is not the case for you.  https://github.com/hassio-addons/repository
  2. Set a password in “Config” section, buycredential_secret, which is used to encrypt sensitive data.
    This is just a “password”, which you should save on a secondary location.
  3. Put true or false under ssl setting depending if you need it. Recommend true if you not sure.
  4. Press Start “Node-RED” add-on.
  5. Check the logs of “Node-RED” to see if everything went well.
  6. Log in with your Home Assistant username/password.
  7. The add-on works straight out the box! No need to configure a server

 BOOM, BEAUTIFUL!  YES, that is it. Frenck you are a genius!

B) Installing Node-RED with Docker

If you are more ambitious, you might have installed Hassbian or on the generic server using docker.  In that case, I recommend you to install Node-red using docker or even better docker-compose method.  

 docker run -d \ –name=node-red \ –restart=always \ -p 1880:1880 \ -u 1000:1000 \ -v /home/adrian/node-red:/data \ nodered/node-red-docker:v8

C) Installing Node-RED with docker-compose.

Even simpler. Just use the configuration by Pshmitt. You might also check out this great tutorial for using a reversed proxy with your setup

nodered:
  image: nodered/node-red-docker:v8
  restart: unless-stopped
  ports:
    – 1880:1880
    – 9229:9229
  volumes:
    – /etc/localtime:/etc/localtime:ro
    – ./data/nodered:/data
  labels:
    – “traefik.enable=true”
    – “traefik.backend=nodered”
    – “traefik.frontend.rule=Host:nodered.home.comreset.io”
    – “traefik.port=1880”

TO CONTINUE with Node-RED, have a look at the other pages:

Was this helpful?

Please let me know in comments if I can update something or if I got something incorrect. I am really hoping to make this page useful and keep it relevant.