# How can we run multiple node-red applications in the same machine/system

**URL:** <https://discourse.nodered.org/t/how-can-we-run-multiple-node-red-applications-in-the-same-machine-system/40805>\
**Category:** General\
**Created:** [11 February 2021 08:03 UTC](https://discourse.nodered.org/t/how-can-we-run-multiple-node-red-applications-in-the-same-machine-system/40805 "2021-02-11T08:03:17Z")\
**Posts on this page:** 19\
**Page:** 1

<div class="post-metadata">

**Author:** ![Syedabd](https://avatars.discourse-cdn.com/v4/letter/s/2acd7d/32.png) [@Syedabd](https://discourse.nodered.org/u/Syedabd)\
**Post date:** [11 February 2021 08:03 UTC](https://discourse.nodered.org/t/how-can-we-run-multiple-node-red-applications-in-the-same-machine-system/40805/1 "2021-02-11T08:03:17Z")

</div>

**For example**  
In other words, Can we able to run on different ports  
The application running in **[http://127.0.0.1:1880/](http://127.0.0.1:1880/)** and the other in **[http://127.0.0.1:1881/](http://127.0.0.1:1881/)**

---

<div class="post-metadata">

**Author:** ![kuema](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/kuema/32/6542_2.png) [@kuema](https://discourse.nodered.org/u/kuema)\
**Post date:** [11 February 2021 08:21 UTC](https://discourse.nodered.org/t/how-can-we-run-multiple-node-red-applications-in-the-same-machine-system/40805/2 "2021-02-11T08:21:54Z")

</div>

When running multiple instances, you need to use different workspaces (default is `.node-red` in your user dir) using the `-u DIRECTORY` parameter when starting Node-RED (depending on how you start it, of course).

In doing so, you can modify the port in the settings.js of each instance's workspace.

Alternatively, you can specify the port using the `-p PORT` parameter.

Also, if you search the forum, there are different solutions to this: [Search results for 'multiple instances' - Node-RED Forum](https://discourse.nodered.org/search?q=multiple%20instances)

---

<div class="post-metadata">

**Author:** ![Syedabd](https://avatars.discourse-cdn.com/v4/letter/s/2acd7d/32.png) [@Syedabd](https://discourse.nodered.org/u/Syedabd)\
**Post date:** [11 February 2021 08:44 UTC](https://discourse.nodered.org/t/how-can-we-run-multiple-node-red-applications-in-the-same-machine-system/40805/3 "2021-02-11T08:44:44Z")

</div>

Alright Got it, What are the steps to point to the JSON file locally using HTTP localhost  
for example;  
I have to create it like this; **[http://localhost:1880/catalogue.json](http://localhost:1880/catalogue.json)'**. This isn't working and the catalogue.json file is in this location **C:\Users\user.node-red\catalogue.json**

please find the screenshot for reference

 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/e/4/e4444130be7b8c6ad7a12cca82e331970022e682.png)

---

<div class="post-metadata">

**Author:** ![Steve-Mcl](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/steve-mcl/32/4826_2.png) [@Steve-Mcl](https://discourse.nodered.org/u/Steve-Mcl)\
**Post date:** [11 February 2021 09:45 UTC](https://discourse.nodered.org/t/how-can-we-run-multiple-node-red-applications-in-the-same-machine-system/40805/4 "2021-02-11T09:45:44Z")

</div>

Can you open `http://localhost:1880/catalogue.json` in a browser? If not, then node-red cannot either.

---

<div class="post-metadata">

**Author:** ![dceejay](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dceejay/32/38_2.png) [@dceejay](https://discourse.nodered.org/u/dceejay)\
**Post date:** [11 February 2021 09:56 UTC](https://discourse.nodered.org/t/how-can-we-run-multiple-node-red-applications-in-the-same-machine-system/40805/5 "2021-02-11T09:56:45Z")

</div>

If you are running multiple instances on multiple ports then you may need to change the catalogue port also... unless they all share that same one. - but yes must have access in e first place.

---

<div class="post-metadata">

**Author:** ![Syedabd](https://avatars.discourse-cdn.com/v4/letter/s/2acd7d/32.png) [@Syedabd](https://discourse.nodered.org/u/Syedabd)\
**Post date:** [11 February 2021 11:09 UTC](https://discourse.nodered.org/t/how-can-we-run-multiple-node-red-applications-in-the-same-machine-system/40805/6 "2021-02-11T11:09:35Z")

</div>

I'm getting this error

 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/3/6/3620517a047abf04bac36331e74d0835140ac0e8.png)

That means its not pointing to catalogue.json file

I'm not able to get the catalogue.json content. So what is the correct path to point catalogue.json file - Considering and running single node application  
My **catalogue.json file is in this location**  **C:\Users\user.node-red\catalogue.json**

What is the correct path I can give it in settings.js  
PFA screenshot of settings.js file

 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/1/6/161ff6f29aa3c205bfa799505c1050315faef77d.png)

---

<div class="post-metadata">

**Author:** ![knolleary](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/knolleary/32/3_2.png) [@knolleary](https://discourse.nodered.org/u/knolleary)\
**Post date:** [11 February 2021 11:14 UTC](https://discourse.nodered.org/t/how-can-we-run-multiple-node-red-applications-in-the-same-machine-system/40805/7 "2021-02-11T11:14:02Z")

</div>

If you want Node-RED to load a catalog from `http://localhost:1880/catalogue.json` then you need to do something to set that up http endpoint.

The `palette.catalogues` setting assumes your are providing URLs.

One option to make that catalogue available would be to use the `httpStatic` setting - that can be used to tell Node-RED to make a particular directory available on its http server.

So you could do:

1. create a directory to contain your static served files - such as `~/.node-red/static`
2. copy you `catalogue.json` into that directory
3. set the `httpStatic` property in your settings file to the full path to that directory - `c:/Users/user/.node-red/static/` (check I've got that path right...)
4. restart Node-RED

---

<div class="post-metadata">

**Author:** ![Syedabd](https://avatars.discourse-cdn.com/v4/letter/s/2acd7d/32.png) [@Syedabd](https://discourse.nodered.org/u/Syedabd)\
**Post date:** [11 February 2021 11:24 UTC](https://discourse.nodered.org/t/how-can-we-run-multiple-node-red-applications-in-the-same-machine-system/40805/8 "2021-02-11T11:24:35Z")

</div>

I have given, but still, it didn't work out  
Please find screenshots below

 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/c/7/c702c5f84eef60de30cffccf957185c4d7c47512.png)  
 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/8/4/8430f596eb990af51f8922a650182c56a539e743.png)  
 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/4/e/4ef2aad04b5f647d8927cd8e0e5eeb33ae4ebfda.png)

---

<div class="post-metadata">

**Author:** ![knolleary](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/knolleary/32/3_2.png) [@knolleary](https://discourse.nodered.org/u/knolleary)\
**Post date:** [11 February 2021 11:26 UTC](https://discourse.nodered.org/t/how-can-we-run-multiple-node-red-applications-in-the-same-machine-system/40805/9 "2021-02-11T11:26:24Z")

</div>

the `httpStatic` property should be set to the **directory containing** catalogue.json - not the file itself.

---

<div class="post-metadata">

**Author:** ![Syedabd](https://avatars.discourse-cdn.com/v4/letter/s/2acd7d/32.png) [@Syedabd](https://discourse.nodered.org/u/Syedabd)\
**Post date:** [11 February 2021 11:29 UTC](https://discourse.nodered.org/t/how-can-we-run-multiple-node-red-applications-in-the-same-machine-system/40805/10 "2021-02-11T11:29:16Z")

</div>

> [@knolleary](#):
>
> directory containing

You mean I just need to give for httpStatic in settings.js file as below  
**httpStatic: 'C:/Users/usre/.node-red/static/'**

---

<div class="post-metadata">

**Author:** ![knolleary](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/knolleary/32/3_2.png) [@knolleary](https://discourse.nodered.org/u/knolleary)\
**Post date:** [11 February 2021 11:30 UTC](https://discourse.nodered.org/t/how-can-we-run-multiple-node-red-applications-in-the-same-machine-system/40805/11 "2021-02-11T11:30:13Z")

</div>

Yes. Sorry, I see I got my instructions wrong previously. I have edited that reply to correct it.

---

<div class="post-metadata">

**Author:** ![Syedabd](https://avatars.discourse-cdn.com/v4/letter/s/2acd7d/32.png) [@Syedabd](https://discourse.nodered.org/u/Syedabd)\
**Post date:** [11 February 2021 11:32 UTC](https://discourse.nodered.org/t/how-can-we-run-multiple-node-red-applications-in-the-same-machine-system/40805/12 "2021-02-11T11:32:42Z")

</div>

Alright, But it still didn't work out

 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/2/1/2156e1b6d78c643357a3fc246b5b14a89c1f508a.png)  
 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/e/7/e7c13e139b7e8f6e11ab50de420fe8d3daf92bc7.png)

---

<div class="post-metadata">

**Author:** ![knolleary](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/knolleary/32/3_2.png) [@knolleary](https://discourse.nodered.org/u/knolleary)\
**Post date:** [11 February 2021 11:34 UTC](https://discourse.nodered.org/t/how-can-we-run-multiple-node-red-applications-in-the-same-machine-system/40805/13 "2021-02-11T11:34:00Z")

</div>

The url for the catalog is `http://localhost:1880/catalogue.json` - it looks like you've included 'static' in the url you are trying.

---

<div class="post-metadata">

**Author:** ![Syedabd](https://avatars.discourse-cdn.com/v4/letter/s/2acd7d/32.png) [@Syedabd](https://discourse.nodered.org/u/Syedabd)\
**Post date:** [11 February 2021 11:35 UTC](https://discourse.nodered.org/t/how-can-we-run-multiple-node-red-applications-in-the-same-machine-system/40805/14 "2021-02-11T11:35:53Z")

</div>

I changed to the above URL as specified, and restarted the node-red.Seems like it's still failing to load

 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/5/3/53d92b8a2640f994b0947026d311008d1ee6fbf7.png)

---

<div class="post-metadata">

**Author:** ![Syedabd](https://avatars.discourse-cdn.com/v4/letter/s/2acd7d/32.png) [@Syedabd](https://discourse.nodered.org/u/Syedabd)\
**Post date:** [11 February 2021 11:41 UTC](https://discourse.nodered.org/t/how-can-we-run-multiple-node-red-applications-in-the-same-machine-system/40805/15 "2021-02-11T11:41:46Z")

</div>

I got it knolleary. I was able to load the catalogues. Thanks a bunch  
This I was running for single node-red  
But to run a multiple node-red application  
Can you please suggest steps to  
**How can I run multiple node-red applications in the same system** and I need to show different catalogues for different ports

---

<div class="post-metadata">

**Author:** ![knolleary](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/knolleary/32/3_2.png) [@knolleary](https://discourse.nodered.org/u/knolleary)\
**Post date:** [11 February 2021 12:16 UTC](https://discourse.nodered.org/t/how-can-we-run-multiple-node-red-applications-in-the-same-machine-system/40805/16 "2021-02-11T12:16:12Z")

</div>

That has already been answered. By giving each instance its own userDir (`-u`) they each have their own settings file and catalogue.json file.

---

<div class="post-metadata">

**Author:** ![Syedabd](https://avatars.discourse-cdn.com/v4/letter/s/2acd7d/32.png) [@Syedabd](https://discourse.nodered.org/u/Syedabd)\
**Post date:** [16 February 2021 06:26 UTC](https://discourse.nodered.org/t/how-can-we-run-multiple-node-red-applications-in-the-same-machine-system/40805/17 "2021-02-16T06:26:31Z")

</div>

Thanks, @knolleary.I got it

a. But in one single instance, i.e say ([http://127.0.0.1:1880/](http://127.0.0.1:1880/)), I must be able to log in with different users

Secondly,  
When User X logins to [http://127.0.0.1:1880/](http://127.0.0.1:1880/), X must be able to see **only User X** flows and catalogues  
When User Y logins to [http://127.0.0.1:1880/](http://127.0.0.1:1880/), Y must be able to see **only User Y** flows and catalogues

---

<div class="post-metadata">

**Author:** ![dceejay](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dceejay/32/38_2.png) [@dceejay](https://discourse.nodered.org/u/dceejay)\
**Post date:** [16 February 2021 08:40 UTC](https://discourse.nodered.org/t/how-can-we-run-multiple-node-red-applications-in-the-same-machine-system/40805/18 "2021-02-16T08:40:49Z")

</div>

See the thread you also opened [here](https://discourse.nodered.org/t/one-instance-multiple-user-logins/41063/3).

---

<div class="post-metadata">

**Author:** ![dceejay](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dceejay/32/38_2.png) [@dceejay](https://discourse.nodered.org/u/dceejay)\
**Post date:** [16 February 2021 08:41 UTC](https://discourse.nodered.org/t/how-can-we-run-multiple-node-red-applications-in-the-same-machine-system/40805/19 "2021-02-16T08:41:00Z")

</div>


