config.prod.js 2.0 KB

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