config.default.js 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. 'use strict';
  2. module.exports = appInfo => {
  3. const config = (exports = {});
  4. // use for cookie sign key, should change to your own and keep security
  5. config.keys = appInfo.name + '_1517455121740_8202';
  6. // add your config here
  7. // config.middleware = [];
  8. config.cluster = {
  9. listen: {
  10. port: 8105
  11. }
  12. };
  13. config.errorMongo = {
  14. details: true
  15. };
  16. config.errorHanler = {
  17. details: true
  18. };
  19. // add redis
  20. config.redis = {
  21. client: {
  22. port: 6379,
  23. host: '127.0.0.1',
  24. password: '',
  25. db: 0,
  26. },
  27. };
  28. // mongoose config
  29. // config.mongoose = {
  30. // url: 'mongodb://localhost:27017/cms',
  31. // options: {
  32. // user: 'root',
  33. // pass: 'Ziyouyanfa#@!',
  34. // authSource: 'admin',
  35. // useNewUrlParser: true,
  36. // useCreateIndex: true,
  37. // useUnifiedTopology: true,
  38. // }
  39. // };
  40. config.mongoose = {
  41. url: 'mongodb://localhost:27017/cms',
  42. options: {
  43. user: 'cms',
  44. pass: 'cms2019',
  45. authSource: 'admin',
  46. useNewUrlParser: true,
  47. useCreateIndex: true,
  48. useUnifiedTopology: true,
  49. }
  50. };
  51. // // base路径
  52. // config.baseDir = 'http://smart.cc-lotus.info';
  53. // // 企业信息url
  54. // config.corpsDir = '/api/corp/corps/';
  55. // // 学校信息url
  56. // config.schsDir = '/api/sch/schs/';
  57. // // 招聘简章url
  58. // config.profilesDir = '/api/jobs/profiles/';
  59. // // 双选会url
  60. // config.fairsDir = '/api/jobs/fairs/';
  61. // 短信验证码接口url
  62. config.messageDir = 'http://sms.bdt360.com:8180/Service.asmx/SendMessageStr';
  63. return config;
  64. };