|
How to Run Any Node.js Application as a Windows Service with AlwaysUp |
Start your Node.js script when your PC boots and keep it running 24/7 in the background. No need to log in!
Node.js is a platform for building scalable, server-side Javascript applications.
AlwaysUp includes advanced tools to make Node.js start at boot and run 24/7.
The Application Advisor will help you install Node.js as a Windows Service with all our recommended settings — in just a few clicks. Simply select Advisor from the Application menu and follow the straightforward prompts.
To configure your Node.js script as a Windows Service with AlwaysUp 8.0 and later:
-
Download and install and configure Node.js, if necessary.
-
Download and install AlwaysUp, if necessary.
-
Start AlwaysUp.
-
Select Application > Add to open the Add Application window:
-
On the General tab:
-
In the Application field, enter the full path to the Node.js executable, node.exe.
By default, this will be:
C:\Program Files\nodejs\node.exe
-
In the Arguments field, enter the full path to your Node.js script, enclosing the entire thing in quotes if it has a space.
We have specified our slightly modified version of the sample web server script mentioned on the Node.js home page,
saved as C:\Scripts\web-server.js.
-
In the Name field, enter the name that you will call the application in AlwaysUp.
We have specified Node.js Server but you can specify another name if you like.
-
Click over to the Startup tab and check the Ensure that the Windows Networking components have started box.
This informs AlwaysUp that Node.js needs TCP/IP networking support to do its work.
-
Click the Save >> button. In a couple of seconds, an application called Node.js Server will show up in the AlwaysUp window.
It is not yet running though.
-
To start your application from AlwaysUp, choose Application > Start "Node.js Server":
Note that Node.js will be running in Session 0. If you are on Windows 2012/8/7/2008/Vista, you can select Tools > Switch to Session 0... to see the usual console window running in the
isolated Session 0:
-
That's it! Next time your computer boots, your Node.js application will start up immediately, before anyone logs on.
We encourage you to edit your application in AlwaysUp and check out the many other settings that may be appropriate for your environment.
For example, send email alerts if the application stops, boost its priority, etc.
Node.js not working properly as a Windows Service?
-
From AlwaysUp, select Application > Report Activity > Today... to bring up a HTML report detailing the interaction between AlwaysUp and your application.
The AlwaysUp Event Log Messages page explains the more obscure messages.
- Consult the AlwaysUp FAQ for answers to commonly asked questions and troubleshooting tips.
- Contact us and we will be happy to help!
|
Over 94,000 installations, and counting!
|
|
|
Rock-solid for the past 19+ years!
|
Fully Compatible with 160+ Applications...
|