Install node red

How to install node red on particular directory on windows?
eg
npm install D:\abc\def\Node-red --unsafe-perm node-red

its not working please let me know how to do that thanks

what i do in cmd is:

cd "D:\abc\def\Node-red"

and then:

npm i node-red

U can read NPM documentation too
A simple google search can help a lot

after installing this error came

npm has two ways of installing modules - either as a local module or a global module.

When installed as a global module (by using the -g option) then it will place any scripts the module provides onto your path so they can be run from anywhere.

When installed as a local module (as you are doing here) then it does not put the scripts onto your path.

To run node-red when it has been installed into a local directory you would run:

node node_modules/node-red/red.js

You may also want to look at New Utility: alternate-node-red-installer

When installing locally and not globally, the command can be found from the installation folder:
"D: \ abc \ def \ Node-red \ node_modules \ .bin \ node-red.cmd"
You can use this file to run node-red or create a service with nssm. I recommend you take a look at the documentation:
https://nodered.org/docs/getting-started/local
Look at Comand line

node node node_modules/node-red/red.js
this working fine thank you
but flows created C:\Users\user.node-red (default)
can we change this in to custom directory?

Yes - look at the docs @Nxito pointed you at - https://nodered.org/docs/getting-started/local#command-line-usage

You can use all the same command-line arguments when using node node_modules/..... as you can with the node-red command.

I put up an article on different ways to install Node-RED:

Obviously, the official docs should be read first.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.