I am going to be in the middle of nowhere for 10 days later this summer. I have a service that needs to stay running and if there is a problem when I am gone, I want to give one or two trusted people access to be able to restart that service. The service is a node.js application and even though they are very technical, I want it to be as simple as running a script via SSH (or a better option if there is one). What would be the best approach to accomplish this?
|
Just setup additional account for trusted people. Allow for this account only start/stop/restart operation for node.js application. After all, you could manage your app with following example script:
After that run it like this:
|
|||
|
|
|
||||
|
|
|
Configure The easiest off course is if you have an init script that does all the required things. Then all you need is to grant these users That way you don't have to change anything to your setup and you're certain everything will be started with all the correct parameters and settings and such. |
|||
|
|
|
To avoid the need for a second person altogether, you should probably be using a watchdog type software to keep the service up. There are many different tools used on Linux to do this, such as:
Luckily, there is a node.js specific app called ' The quick way is:
|
|||||||||
|
