config.dev.js 2.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798
  1. "use strict";
  2. // 三师后台数据库配置
  3. let wlyyDbConfig = {
  4. host: '172.19.103.77',
  5. user: 'root',
  6. password: '123456',
  7. database: 'wlyy',
  8. connectionLimit: '50',
  9. charset: 'utf8mb4'
  10. };
  11. // IM数据库配置
  12. let imDbConfig = {
  13. host: '172.19.103.77',
  14. user: 'root',
  15. password: '123456',
  16. database: 'ichat',
  17. connectionLimit: '50',
  18. charset: 'utf8mb4'
  19. };
  20. // Redis
  21. let redisConfig = {
  22. host: '192.168.1.220',
  23. port: 6379,
  24. db: 1
  25. };
  26. // 三师后台
  27. let wlyyServerConfig = {
  28. host: '172.19.103.87',
  29. port: 9092
  30. };
  31. // 透传服务
  32. let transServerConfig = {
  33. host: '172.19.103.76',
  34. port: 8000
  35. };
  36. // 企业版的推送配置
  37. let geTuiConfig = {
  38. HOST: 'https://api.getui.com/apiex.htm',
  39. APPID: 'qWmRh2X88l7HuE36z3qBe8',
  40. APPKEY: 'EzERfV8c849lBkZqHWzQG1',
  41. MASTERSECRET: 'veXiajQrId6iojy7Qv8kZ2'
  42. };
  43. // AppStore版的推送App配置
  44. let geTuiAppStoreCfg = {
  45. HOST: 'https://api.getui.com/apiex.htm',
  46. APPID: 'H6FYbDejks6VjMmW3uH7V6',
  47. APPKEY: '0PFWlKmLBN9YzhCfFWVgYA',
  48. MASTERSECRET: 'pvjCGtRZJx9SRVODkxc816'
  49. };
  50. // 微信配置
  51. let wechatConfig = {
  52. appId: 'wxd03f859efdf0873d',
  53. appSecret: '2935b54b53a957d9516c920a544f2537',
  54. token: '27eb3bb24f149a7760cf1bb154b08040',
  55. baseUrl: 'weixin.xmtyw.cn/wlyy',
  56. template: {
  57. consultTemplate: 'qSOW0DBxO3qEBm4ucG0Ial0jxsOyD7_f2TFK5e-mQEc' // 咨询回复模板
  58. }
  59. };
  60. // 会话配置
  61. let sessionConfig = {
  62. maxMessageCount: 1000, // 会话缓存的消息数量
  63. maxMessageTimespan: 7 * 24 * 3600, // 会话缓存的最大时间跨度
  64. expireTime: 3 * 60 * 60 * 1000, // 会话过期时间,以毫秒计
  65. expireSessionCleanCount: 10, // 每次清理多少个过期会话
  66. MUC:"1", //session模式配置
  67. P2P:"2",
  68. TEAM:"3"
  69. };
  70. exports.app = 'IM.Server';
  71. exports.version = '2.0.0';
  72. exports.debug = true;
  73. exports.serverPort = 3008;
  74. exports.sessionExpire = 1800;
  75. exports.showSQL = true;
  76. exports.wlyyDbConfig = wlyyDbConfig;
  77. exports.imDbConfig = imDbConfig;
  78. exports.redisConfig = redisConfig;
  79. exports.geTuiConfig = geTuiConfig;
  80. exports.geTuiAppStoreCfg = geTuiAppStoreCfg;
  81. exports.wlyyServerConfig = wlyyServerConfig;
  82. exports.transServerConfig = transServerConfig;
  83. exports.wechatConfig = wechatConfig;
  84. exports.sessionConfig = sessionConfig;