Run a Npm Start Script With PM2
How to Run a Npm Start Script With PM2 August 02, 2019 / NodeJS Are you looking for a way to run npm start scripts with PM2 ? Or how to to do so while also using the options commands with it as well? In this article, we will go through some examples that will help you achieve this. If you haven't already, you can install PM2 globally on your machine with this command: Command Copy npm install pm2 -g Once you have the NPM package installed, you'll be good to go with using the examples in this article! Table Of Contents NPM Start Script NPM Start Script With the App Name Option NPM Start Script With Multiple Options NPM Start Script To run the npm start script with PM2, you can use the following command (make sure you call the command from inside your project folder): Command Copy pm2 start npm -- start And you should see a similar output in your command prompt: Output [PM2] Starting /usr/bin/npm in fork_mode (1 instance) [PM2] Done. ┌──────────┬────┬─...