############################################################################## # PM2 ############################################################################## # Start commands pm2 start # Start an application pm2 start # Start a stopped application pm2 start ecosystem.config.js # Start an app with the configuration in ecosystem file pm2 start -i # Start an app in cluster mode with n duplicated instances # Management commands pm2 ls # List all processes pm2 save # Save process list to respawn at reboot pm2 restart # Restart an app by ID pm2 reload # Reload an app by ID pm2 stop # Stop an app by ID pm2 stop all # Stop all running instances pm2 delete # Delete an app by ID pm2 delete all # Delete all instances pm2 ecosystem # Generate a sample ecosystem.config.js file # Monitoring pm2 show # Show a specific app's description pm2 logs --lines= # Show the last n lines of logs of an app pm2 env # Show all environment variables of an app pm2 monit # Monitor all applications' logs, metrics,etc