Node-server for unitstock app
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

33 lines
711 B

  1. module.exports = {
  2. apps : [{
  3. name: 'unit-stock',
  4. script: 'server.js',
  5. // Options reference: https://pm2.io/doc/en/runtime/reference/ecosystem-file/
  6. args: 'one two',
  7. instances: 2,
  8. autorestart: true,
  9. watch: false,
  10. max_memory_restart: '1G',
  11. env: {
  12. NODE_ENV: 'development',
  13. PORT: 14002
  14. },
  15. env_production: {
  16. NODE_ENV: 'production',
  17. PORT: 14002
  18. }
  19. }],
  20. deploy : {
  21. production : {
  22. user : 'node',
  23. host : '212.83.163.1',
  24. ref : 'origin/master',
  25. repo : 'git@github.com:repo.git',
  26. path : '/var/www/production',
  27. 'post-deploy' : 'npm install && pm2 reload ecosystem.config.js --env production'
  28. }
  29. }
  30. };