init project
This commit is contained in:
commit
571ba2a8a1
34 files changed
+3618
No files matched your search
@@ -0,0 +1,40 @@
|
||||
'use strict';
|
||||
|
||||
const path = require('path');
|
||||
|
||||
module.exports = appInfo => {
|
||||
|
||||
return {
|
||||
static: {
|
||||
maxAge: 0,
|
||||
buffer: false,
|
||||
preload: false,
|
||||
maxFiles: 0,
|
||||
},
|
||||
logger: {
|
||||
outputJSON: true,
|
||||
consoleLevel: 'DEBUG',
|
||||
level: 'DEBUG',
|
||||
dir: path.join(appInfo.baseDir, 'logs'),
|
||||
contextFormatter(meta) {
|
||||
return `[${meta.date}] [${meta.level}] [${meta.ctx.method} ${meta.ctx.url}] ${meta.message}`;
|
||||
}
|
||||
},
|
||||
knex: {
|
||||
client: {
|
||||
dialect: 'mysql',
|
||||
connection: {
|
||||
host: '127.0.0.1',
|
||||
port: 3306,
|
||||
user: 'root',
|
||||
password: '123456',
|
||||
database: 'xianfeng-v1'
|
||||
},
|
||||
pool: { min: 0, max: 30 },
|
||||
acquireConnectionTimeout: 30000
|
||||
},
|
||||
app: true
|
||||
}
|
||||
};
|
||||
|
||||
};
|
||||
Reference in new issue
Block a user