So I'm really new into loading the node server on AWS, basically I followed some guide to start node from etc/init
so I have a file like that in etc/init
menuserver.conf
#!upstart
description "menu-creator server"
start on started mountall
stop on shutdown
# Automatically Respawn:
respawn
respawn limit 99 5
env NODE_ENV=development
# Warning: this runs node as root user, which is a security risk
# in many scenarios, but upstart-ing a process as a non-root user
# is outside the scope of this question
exec node /home/ec2-user/MenuCreator/app.js >> /var/log/yourappname.log 2>&1
I have updated the server code, and wish to restart the server, how to do it? as I'm just starting out, I don't care so much for the security risks.
I've tried etc/init.d/menuserver restart, but actually menuserver isn't found in init.d.
looking for a quick way to restart the program, and also for a long term good practice guide for how to setup and restart the server. (I think I heard Forever is recommended... is it?)