config.prod.js 1.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. "use strict";
  2. let imDbConfig = {
  3. host: '59.61.92.94',
  4. user: 'im',
  5. password: 'im!)123',
  6. database: 'im',
  7. connectionLimit: '100',
  8. charset : 'utf8mb4'
  9. };
  10. // Redis
  11. let redisConfig = {
  12. host: '120.41.253.95',
  13. port: 6380,
  14. db: 1,
  15. password:'jkzl_ehr'
  16. };
  17. // 三师后台
  18. let wlyyServerConfig = {
  19. host: '120.41.252.108',
  20. port: 9660
  21. };
  22. // 个推AppStore版参数
  23. let getTuiConfig = {
  24. HOST: 'https://api.getui.com/apiex.htm',
  25. APPID: 'qWmRh2X88l7HuE36z3qBe8',
  26. APPKEY: 'EzERfV8c849lBkZqHWzQG1',
  27. MASTERSECRET: 'veXiajQrId6iojy7Qv8kZ2'
  28. };
  29. // 微信配置
  30. let wechatConfig = {
  31. appId: 'wxad04e9c4c5255acf',
  32. appSecret: 'ae77c48ccf1af5d07069f5153d1ac8d3',
  33. token: '27eb3bb24f149a7760cf1bb154b08040',
  34. baseUrl: 'www.xmtyw.cn/wlyy',
  35. template: {
  36. consultTemplate: '0mF_vHj-ILx8EH8DwzmAi7LqzjqYiU9IrSRRmziTZyc' // 咨询回复模板
  37. }
  38. };
  39. // 会话配置
  40. let sessionConfig = {
  41. maxMessageCount: 1000, // 会话缓存的消息数量
  42. maxMessageTimespan: 7 * 24 * 3600, // 会话缓存的最大时间跨度
  43. expireTime: 3 * 60 * 60 * 1000, // 会话过期时间,以毫秒计
  44. expireSessionCleanCount: 10 // 每次清理多少个过期会话
  45. };
  46. // 议题配置
  47. let topicConfig = {
  48. TTL: 24, // 议题的存活时间,TTL = Time To Live
  49. TERMINATING_CRON: "* 59 * * * *" // 议题自动关闭的任务执行时间间隔
  50. };
  51. exports.app = 'im.server';
  52. exports.version = '2.0.0';
  53. exports.debug = true;
  54. exports.serverPort = 3000;
  55. exports.sessionExpire = 1800;
  56. exports.showSQL = false;
  57. exports.imDbConfig = imDbConfig;
  58. exports.redisConfig = redisConfig;
  59. exports.getTuiConfig = getTuiConfig;
  60. exports.wlyyServerConfig = wlyyServerConfig;
  61. exports.wechatConfig = wechatConfig;
  62. exports.sessionConfig = sessionConfig;
  63. exports.topicConfig = topicConfig;