feat: depoly on now serverless function (#4554)

This commit is contained in:
fengkx
2020-04-28 17:28:57 +08:00
committed by GitHub
parent f5c6d6e100
commit 7902c547cf
6 changed files with 30 additions and 2 deletions

View File

@@ -1,3 +1,4 @@
const { resolve } = require('path');
const winston = require('winston');
const config = require('@/config').value;
@@ -10,10 +11,10 @@ const logger = winston.createLogger({
// - Write all logs error (and below) to `error.log`.
//
new winston.transports.File({
filename: 'logs/error.log',
filename: resolve('logs/error.log'),
level: 'error',
}),
new winston.transports.File({ filename: 'logs/combined.log' }),
new winston.transports.File({ filename: resolve('logs/combined.log') }),
],
});