1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52
| const path = require('path');
module.exports = { appenders: { access: { type: 'dateFile', filename: path.join(__dirname, '../logs/access.log'), pattern: '.yyyy-MM-dd', numBackups: 30, compress: true }, application: { type: 'dateFile', filename: path.join(__dirname, '../logs/app.log'), pattern: '.yyyy-MM-dd', numBackups: 30, compress: true }, error: { type: 'dateFile', filename: path.join(__dirname, '../logs/error.log'), pattern: '.yyyy-MM-dd', numBackups: 90, compress: true }, console: { type: 'stdout' } }, categories: { default: { appenders: ['console', 'application'], level: 'info' }, access: { appenders: ['access'], level: 'info' }, error: { appenders: ['console', 'error'], level: 'error' } }, pm2: true, pm2InstanceVar: 'INSTANCE_ID' };
|