config.autotest.js 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. 'use strict';
  2. /**
  3. * 开发环境相关配置
  4. *
  5. * @author CaiAoLin
  6. * @date 2017/8/29
  7. * @version
  8. */
  9. module.exports = appInfo => {
  10. const config = {};
  11. // 数据库配置
  12. config.mysql = {
  13. client: {
  14. // host
  15. host: '192.168.1.70',
  16. // 端口号
  17. port: '3306',
  18. // 用户名
  19. user: 'root',
  20. // 密码
  21. password: 'root',
  22. // 数据库名
  23. database: 'calc_test',
  24. },
  25. // 是否加载到 app 上,默认开启
  26. app: true,
  27. // 是否加载到 agent 上,默认关闭
  28. agent: false,
  29. };
  30. // redis设置
  31. config.redis = {
  32. client: {
  33. host: '192.168.1.70',
  34. port: '6379',
  35. password: 'test',
  36. db: '0',
  37. },
  38. agent: true,
  39. version: '1.0.0',
  40. };
  41. // 前端验证
  42. config.jsValidator = {
  43. client: {},
  44. app: true,
  45. };
  46. // 是否压缩替换前端js
  47. config.min = false;
  48. config.logger = {
  49. consoleLevel: 'WARN',
  50. disableConsoleAfterReady: false,
  51. };
  52. return config;
  53. };