title: pm2: how to switch multiple app declaration json inside docker
body: <p>In my Dockerfile, there is</p>
  
  <pre><code>CMD ["pm2", "start", "app.json"]
  </code></pre>
  
  <p>If I have two json files, app.prod.json and app.dev.json, how to switch them when running docker containers?</p>
  
  <p>my app.json:</p>
  
  <pre><code>{
      'apps': [{
          'name'      : 'app1',
          'script'    : 'src/app.py',
          'instance'  : 2,
          'exec_mode' : 'fork',
          'args'      : ['-g', 'test'],
      },{
          'name'      : 'app2',
          'script'    : 'src/app.py',
          'instance'  : 2,
          'exec_mode' : 'fork',
          'args'      : ['-g', 'test'],
      }]
  }           
  </code></pre>
  
  <p>In fact, I need to switch the args in above json file when running docker containers. I know that it may be easy to do this in Node.js by setting NODE_ENV, but I am trying to run python scripts.</p>
  
  <p>Any comments welcomed. Thank you.</p>