cool-admin-midway/src/config/config.local.ts
2022-03-21 09:44:27 +08:00

27 lines
608 B
TypeScript

import { CoolConfig } from '@cool-midway/core';
import { MidwayConfig } from '@midwayjs/core';
/**
* 本地开发 npm run dev 读取的配置文件
*/
export default {
orm: {
type: 'mysql',
host: '127.0.0.1',
port: 3306,
username: 'root',
password: '123456',
database: 'cool',
// 自动建表 注意:线上部署的时候不要使用,有可能导致数据丢失
synchronize: true,
// 打印日志
logging: true,
// 字符集
charset: 'utf8mb4',
},
cool: {
// 是否自动导入数据库
initDB: true,
} as CoolConfig,
} as MidwayConfig;