title: NodeJS passing command line arguments to forever
body: <p>Im trying to pass command line arguments to forever, that I want to parse in my app.</p>
  
  <p>Currently I'm starting my app like this:</p>
  
  <pre><code>forever start -c "node --max-old-space-size=8192 --nouse-idle-notification" /home/ubuntu/node/server.js
  </code></pre>
  
  <p>I want to be able to read some arguments in my server.js.</p>
  
  <p>My code for reading:</p>
  
  <pre><code>var arguments = process.argv.slice(2);
  console.log(arguments[0]);
  
  if(!arguments[0]) {
      console.log("Error: Missing port.");
      process.exit(1);
  }
  </code></pre>
  
  <p>But how to I tell <code>forever</code> to pass arguments that can be read inside <code>server.js</code>?</p>