config.default.js 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. /* eslint valid-jsdoc: "off" */
  2. 'use strict';
  3. /**
  4. * @param {Egg.EggAppInfo} appInfo app info
  5. */
  6. module.exports = appInfo => {
  7. /**
  8. * built-in config
  9. * @type {Egg.EggAppConfig}
  10. **/
  11. const config = exports = {};
  12. // use for cookie sign key, should change to your own and keep security
  13. config.keys = appInfo.name + '_1617689037805_3801';
  14. // add your middleware config here
  15. config.middleware = [];
  16. // add your user config here
  17. const userConfig = {
  18. // myAppName: 'egg',
  19. };
  20. config.cluster = {
  21. listen: {
  22. port: 9104,
  23. },
  24. };
  25. config.dbName = 'question';
  26. config.mongoose = {
  27. url: `mongodb://localhost:27017/${config.dbName}`,
  28. options: {
  29. user: 'admin',
  30. pass: 'admin',
  31. authSource: 'admin',
  32. useNewUrlParser: true,
  33. useCreateIndex: true,
  34. },
  35. };
  36. config.project = {
  37. live: 'http://127.0.0.1:9101/api/live/v0',
  38. };
  39. config.baseUrl = 'http://broadcast.waityou24.cn';
  40. config.wxapi = {
  41. appid: 'wx6db5d25b3e7cfc14', // 微信公众号APPID
  42. baseUrl: 'http://wx.cc-lotus.info', // 微信网关地址
  43. };
  44. config.export = {
  45. root_path: 'S:\\workspace\\exportFile',
  46. domain: 'http://broadcast.waityou24.cn',
  47. };
  48. return {
  49. ...config,
  50. ...userConfig,
  51. };
  52. };