node-red-contrib-storagemodule-postgres

1.0.1 • Public • Published

node-red-contrib-storagemodule-postgres

A module to provide Node-RED persistence using a postgres database instead of the default filesystem.

More info here: Node-RED Storage API

How to use:

Add to your settings.js (normally found in '/home/yourHomeDirectory/.node-red/'):

    storageModule: require("node-red-contrib-storagemodule-postgres"),
    postgresURI: "postgres://username:password@postgressIP:5432/database",
    postgresSchema: "public",   //optional, defaults to the public schema
    // Enable module reinstalls on start-up; this ensures modules installed post-deploy are restored after a restage
    autoInstallModules: true,

    userDir: '/home/yourHomeDirectory/.node-red/', //required to install nodes via the palette manager

In the same directory ('/home/yourHomeDirectory/.node-red/'), run:

npm install node-red-contrib-storagemodule-postgres

How it works:

This module creates 2 new tables in your postgres database:

  • nodered
  • noderedlibrary

Currently not implemented:

  • sessions
  • projects
  • Doesn't log nicely, doesn't throw errors (just prints them)

Readme

Keywords

Package Sidebar

Install

npm i node-red-contrib-storagemodule-postgres

Weekly Downloads

1

Version

1.0.1

License

MIT

Unpacked Size

7.32 kB

Total Files

4

Last publish

Collaborators

  • weekendwarrior