How to restart a NodeJS application

1 de noviembre, 2015 @ 14:02 — 0 comentariosDownload PDF

In this guide we explain two different methods to restart NodeJS applications.

Restart from the Hosting Panel

1 - Access your Hosting Panel

Just follow instructions in How to access your Hosting Panel.

2 - Click on NodeJS Applications

Look for and click on NodeJS Applications icon.


3 - Restart app

You will see a listing of all NodeJS applications configured in the current hosting account. Just locate the one you wish to restart and click on its Reboot link.


Restart creating a restart.txt file

The second method to restart an application is usually more convenient, as it only requires to create or update a file named restart.txt that must be located in the tmp folder of you NodeJS application.

In other words: if your applications root folder is /home/username/nodejs/mynode you must create or update the file /home/username/nodejs/mynode/tmp/restart.txt

Just access your account using SSH and execute:

cd /home/username/nodejs/mynode
touch tmp/restart.txt