# NSSM setup on the Alternate install of Node-Red

**URL:** <https://discourse.nodered.org/t/nssm-setup-on-the-alternate-install-of-node-red/78107>\
**Category:** General\
**Created:** [2 May 2023 13:26 UTC](https://discourse.nodered.org/t/nssm-setup-on-the-alternate-install-of-node-red/78107 "2023-05-02T13:26:40Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![ccoggins](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/ccoggins/32/79466_2.png) [@ccoggins](https://discourse.nodered.org/u/ccoggins)\
**Post date:** [2 May 2023 13:26 UTC](https://discourse.nodered.org/t/nssm-setup-on-the-alternate-install-of-node-red/78107/1 "2023-05-02T13:26:41Z")

</div>

Hello,  
I did an Alternate Install of Node-Red because the server I am installing Node-Red on does not have access to the internet.

I started by doing the alternate installer on my own pc and then installed all the modules I wanted.  
Copied the node-red install to C:\Node-Red

I am stuck on trying to figure out how to get Node-Red to run as a service from this directory.

I downloaded NSSM and tried a few of the install commands to create the service in Windows, but I am unable to get the services to start.

```auto
nssm install Node-Red C:\Node-Red start

"start": "node C:/Node-Red/node_modules/node-red/red.js --userDir ./data"

```

These are a couple of the commands I tried, but none of them worked.  
The "Start" command was not even an option to use.

I tried to find an older version of NSSM like 2.18 because I saw it used to have GUI version that looked pretty simple to use for this process.  
You would just use  
NPM  
Location  
Start

which is what I believe needs to happen.

Any help would be much appreciated.

Thank you!

Kind regards,  
Chuck

---

<div class="post-metadata">

**Author:** ![ccoggins](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/ccoggins/32/79466_2.png) [@ccoggins](https://discourse.nodered.org/u/ccoggins)\
**Post date:** [2 May 2023 17:45 UTC](https://discourse.nodered.org/t/nssm-setup-on-the-alternate-install-of-node-red/78107/2 "2023-05-02T17:45:06Z")

</div>

Nevermind I found a way around all of this.  
I created a batch file

```auto
@echo off
cd c:\node-red
npm start

```

I saved this batch file in the location: c:\node-red\batchfile as startup.bat

Then I had NSSM install it as a service  
`nssm install Node-Red "C:\node-red\batchfile\startup.bat"`

This works you just need to give the batch file a few seconds to load fully before the Node-Red GUI website is available.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)\
**Post date:** [16 May 2023 17:45 UTC](https://discourse.nodered.org/t/nssm-setup-on-the-alternate-install-of-node-red/78107/3 "2023-05-16T17:45:44Z")

</div>

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