Use pgrep/pkill! 😉
or even shorter with pkillpkill -USR1 -f "app.js"
Substitute -USR1 with -SIGHUP and you got yourself a quick and easy build-tool command to restart NodeBB, when changing files. 🙂
(I'm using SublimeText / Atom)
Are there any more docs on this method of deployment? I was currently creating my own config.json file and then attempting to run the nodebb setup. This seems like a possibly easier way of doing it. Example from the above post would not typically be how I would set environment variables:
# Minimum setup options $ database=redis node app --setup`
I pass all my environment variables from a shell script during the deployment stage. The addition of 'node app --setup' here I believe is just running the setup script after the variables are set correct?
$ ./nodebb help setup Usage: setup [options] [config] Run the NodeBB setup script, or setup with an initial config Options: -h, --help output usage information
You can provide a JSON object as the config parameter to that command.
@PitaJ OR it can read from environment variables?
(Which is what is discussed in the link I gave above)