title: Run a custom npm script with PM2
body: <p>I am currently developing several Telegram bots but I want to keep all of them in the same git repository. The issue is that on the other hand, I want to run them as separate processes.</p>
  
  <p>Since I'm using the Telegraf framework, to run a bot it goes such as: <code>micro-bot src/bot-one/bot.js</code></p>
  
  <p>The problem comes when doing this with PM2. I've been able to run one of the bots with the <code>npm start</code> script like this:</p>
  
  <pre><code>pm2 start --name "WeatherBot" npm -- start -- -t &lt;
  TOKEN&gt;
  </code></pre>
  
  <p>But I'd like to be able to create custom scripts like this:</p>
  
  <pre><code>"main": "src/weatherWarnBot/bot.js",
  "scripts": {
      "start": "micro-bot",
      "littleAppleBot": "micro-bot src/littleAppleBot/bot.js",
      "weatherWarnBot": "micro-bot src/weatherWarnBot/bot.js"
  }
  </code></pre>
  
  <p>But, how would the PM2 command be to run each of the two custom scripts? I was thinking of having the bot tokens set as enviroment variables of the system, for simplification.</p>