| 12345678910111213141516171819202122232425262728293031323334 |
- module.exports = {
- apps: [{
- name: 'order-shipping',
- script: './server/index.js',
- instances: 1,
- autorestart: true,
- watch: false,
- max_memory_restart: '512M',
- env: {
- NODE_ENV: 'production',
- PORT: 3000,
- // 数据库配置(可通过环境变量覆盖)
- DB_HOST: '121.37.183.152',
- DB_PORT: 5432,
- DB_NAME: 'lp-card-test',
- DB_USER: 'postgres',
- DB_PASSWORD: '123456',
- },
- // 生产环境取消下面注释,填入生产数据库信息
- // env_production: {
- // NODE_ENV: 'production',
- // PORT: 3000,
- // DB_HOST: 'pgm-uf69f8n00s9mqn91go.pg.rds.aliyuncs.com',
- // DB_PORT: 5432,
- // DB_NAME: 'gt_fmzgo',
- // DB_USER: 'gtfmzgo',
- // DB_PASSWORD: 'Bm123456@',
- // },
- log_date_format: 'YYYY-MM-DD HH:mm:ss',
- error_file: './logs/pm2-error.log',
- out_file: './logs/pm2-out.log',
- merge_logs: true,
- }]
- };
|