application-prod.yml 9.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253
  1. --- # 临时文件存储位置 避免临时文件被系统清理报错
  2. spring.servlet.multipart.location: /ruoyi/server/temp
  3. --- # 监控中心配置
  4. spring.boot.admin.client:
  5. # 增加客户端开关
  6. enabled: true
  7. url: http://localhost:9090/admin
  8. instance:
  9. service-host-type: IP
  10. username: ruoyi
  11. password: 123456
  12. --- # powerjob 配置
  13. powerjob:
  14. worker:
  15. # 如何开启调度中心请查看文档教程
  16. enabled: false
  17. # 需要先在 powerjob 登录页执行应用注册后才能使用
  18. app-name: ruoyi-worker
  19. enable-test-mode: false
  20. max-appended-wf-context-length: 4096
  21. max-result-length: 4096
  22. # 28080 端口 随着主应用端口飘逸 避免集群冲突
  23. port: 2${server.port}
  24. protocol: http
  25. server-address: 127.0.0.1:7700
  26. store-strategy: disk
  27. --- # 数据源配置
  28. spring:
  29. datasource:
  30. type: com.zaxxer.hikari.HikariDataSource
  31. # 动态数据源文档 https://www.kancloud.cn/tracy5546/dynamic-datasource/content
  32. dynamic:
  33. # 性能分析插件(有性能损耗 不建议生产环境使用)
  34. p6spy: false
  35. # 设置默认的数据源或者数据源组,默认值即为 master
  36. primary: master
  37. # 严格模式 匹配不到数据源则报错
  38. strict: true
  39. datasource:
  40. # 主库数据源
  41. master:
  42. type: ${spring.datasource.type}
  43. driverClassName: com.mysql.cj.jdbc.Driver
  44. # jdbc 所有参数配置参考 https://lionli.blog.csdn.net/article/details/122018562
  45. # rewriteBatchedStatements=true 批处理优化 大幅提升批量插入更新删除性能(对数据库有性能损耗 使用批量操作应考虑性能问题)
  46. url: jdbc:mysql://localhost:3306/ry_vue_5.X?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8&autoReconnect=true&rewriteBatchedStatements=true&allowPublicKeyRetrieval=true
  47. username: root
  48. password: root
  49. # 从库数据源
  50. slave:
  51. lazy: true
  52. type: ${spring.datasource.type}
  53. driverClassName: com.mysql.cj.jdbc.Driver
  54. url: jdbc:mysql://localhost:3306/ry-vue?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8&autoReconnect=true&rewriteBatchedStatements=true&allowPublicKeyRetrieval=true
  55. username:
  56. password:
  57. # oracle:
  58. # type: ${spring.datasource.type}
  59. # driverClassName: oracle.jdbc.OracleDriver
  60. # url: jdbc:oracle:thin:@//localhost:1521/XE
  61. # username: ROOT
  62. # password: root
  63. # hikari:
  64. # connectionTestQuery: SELECT 1 FROM DUAL
  65. # postgres:
  66. # type: ${spring.datasource.type}
  67. # driverClassName: org.postgresql.Driver
  68. # url: jdbc:postgresql://localhost:5432/postgres?useUnicode=true&characterEncoding=utf8&useSSL=true&autoReconnect=true&reWriteBatchedInserts=true
  69. # username: root
  70. # password: root
  71. # sqlserver:
  72. # type: ${spring.datasource.type}
  73. # driverClassName: com.microsoft.sqlserver.jdbc.SQLServerDriver
  74. # url: jdbc:sqlserver://localhost:1433;DatabaseName=tempdb;SelectMethod=cursor;encrypt=false;rewriteBatchedStatements=true
  75. # username: SA
  76. # password: root
  77. hikari:
  78. # 最大连接池数量
  79. maxPoolSize: 20
  80. # 最小空闲线程数量
  81. minIdle: 10
  82. # 配置获取连接等待超时的时间
  83. connectionTimeout: 30000
  84. # 校验超时时间
  85. validationTimeout: 5000
  86. # 空闲连接存活最大时间,默认10分钟
  87. idleTimeout: 600000
  88. # 此属性控制池中连接的最长生命周期,值0表示无限生命周期,默认30分钟
  89. maxLifetime: 1800000
  90. # 连接测试query(配置检测连接是否有效)
  91. connectionTestQuery: SELECT 1
  92. # 多久检查一次连接的活性
  93. keepaliveTime: 30000
  94. --- # redis 单机配置(单机与集群只能开启一个另一个需要注释掉)
  95. spring.data:
  96. redis:
  97. # 地址
  98. host: localhost
  99. # 端口,默认为6379
  100. port: 6379
  101. # 数据库索引
  102. database: 0
  103. # 密码(如没有密码请注释掉)
  104. # password:
  105. # 连接超时时间
  106. timeout: 10s
  107. # 是否开启ssl
  108. ssl.enabled: false
  109. redisson:
  110. # redis key前缀
  111. keyPrefix:
  112. # 线程池数量
  113. threads: 16
  114. # Netty线程池数量
  115. nettyThreads: 32
  116. # 单节点配置
  117. singleServerConfig:
  118. # 客户端名称
  119. clientName: ${ruoyi.name}
  120. # 最小空闲连接数
  121. connectionMinimumIdleSize: 32
  122. # 连接池大小
  123. connectionPoolSize: 64
  124. # 连接空闲超时,单位:毫秒
  125. idleConnectionTimeout: 10000
  126. # 命令等待超时,单位:毫秒
  127. timeout: 3000
  128. # 发布和订阅连接池大小
  129. subscriptionConnectionPoolSize: 50
  130. --- # mail 邮件发送
  131. mail:
  132. enabled: false
  133. host: smtp.163.com
  134. port: 465
  135. # 是否需要用户名密码验证
  136. auth: true
  137. # 发送方,遵循RFC-822标准
  138. from: xxx@163.com
  139. # 用户名(注意:如果使用foxmail邮箱,此处user为qq号)
  140. user: xxx@163.com
  141. # 密码(注意,某些邮箱需要为SMTP服务单独设置密码,详情查看相关帮助)
  142. pass: xxxxxxxxxx
  143. # 使用 STARTTLS安全连接,STARTTLS是对纯文本通信协议的扩展。
  144. starttlsEnable: true
  145. # 使用SSL安全连接
  146. sslEnable: true
  147. # SMTP超时时长,单位毫秒,缺省值不超时
  148. timeout: 0
  149. # Socket连接超时值,单位毫秒,缺省值不超时
  150. connectionTimeout: 0
  151. --- # sms 短信 支持 阿里云 腾讯云 云片 等等各式各样的短信服务商
  152. # https://wind.kim/doc/start 文档地址 各个厂商可同时使用
  153. sms:
  154. # 阿里云 dysmsapi.aliyuncs.com
  155. alibaba:
  156. #请求地址 默认为 dysmsapi.aliyuncs.com 如无特殊改变可以不用设置
  157. requestUrl: dysmsapi.aliyuncs.com
  158. #阿里云的accessKey
  159. accessKeyId: xxxxxxx
  160. #阿里云的accessKeySecret
  161. accessKeySecret: xxxxxxx
  162. #短信签名
  163. signature: 测试
  164. tencent:
  165. #请求地址默认为 sms.tencentcloudapi.com 如无特殊改变可不用设置
  166. requestUrl: sms.tencentcloudapi.com
  167. #腾讯云的accessKey
  168. accessKeyId: xxxxxxx
  169. #腾讯云的accessKeySecret
  170. accessKeySecret: xxxxxxx
  171. #短信签名
  172. signature: 测试
  173. #短信sdkAppId
  174. sdkAppId: appid
  175. #地域信息默认为 ap-guangzhou 如无特殊改变可不用设置
  176. territory: ap-guangzhou
  177. --- # 三方授权
  178. justauth:
  179. enabled: true
  180. # 前端外网访问地址
  181. address: http://localhost:80
  182. type:
  183. maxkey:
  184. # maxkey 服务器地址
  185. # 注意 如下均配置均不需要修改 maxkey 已经内置好了数据
  186. server-url: http://sso.maxkey.top
  187. client-id: 876892492581044224
  188. client-secret: x1Y5MTMwNzIwMjMxNTM4NDc3Mzche8
  189. redirect-uri: ${justauth.address}/social-callback?source=maxkey
  190. qq:
  191. client-id: 10**********6
  192. client-secret: 1f7d08**********5b7**********29e
  193. redirect-uri: ${justauth.address}/social-callback?source=qq
  194. union-id: false
  195. weibo:
  196. client-id: 10**********6
  197. client-secret: 1f7d08**********5b7**********29e
  198. redirect-uri: ${justauth.address}/social-callback?source=weibo
  199. gitee:
  200. client-id: 91436b7940090d09c72c7daf85b959cfd5f215d67eea73acbf61b6b590751a98
  201. client-secret: 02c6fcfd70342980cd8dd2f2c06c1a350645d76c754d7a264c4e125f9ba915ac
  202. redirect-uri: ${justauth.address}/social-callback?source=gitee
  203. dingtalk:
  204. client-id: 10**********6
  205. client-secret: 1f7d08**********5b7**********29e
  206. redirect-uri: ${justauth.address}/social-callback?source=dingtalk
  207. baidu:
  208. client-id: 10**********6
  209. client-secret: 1f7d08**********5b7**********29e
  210. redirect-uri: ${justauth.address}/social-callback?source=baidu
  211. csdn:
  212. client-id: 10**********6
  213. client-secret: 1f7d08**********5b7**********29e
  214. redirect-uri: ${justauth.address}/social-callback?source=csdn
  215. coding:
  216. client-id: 10**********6
  217. client-secret: 1f7d08**********5b7**********29e
  218. redirect-uri: ${justauth.address}/social-callback?source=coding
  219. coding-group-name: xx
  220. oschina:
  221. client-id: 10**********6
  222. client-secret: 1f7d08**********5b7**********29e
  223. redirect-uri: ${justauth.address}/social-callback?source=oschina
  224. alipay_wallet:
  225. client-id: 10**********6
  226. client-secret: 1f7d08**********5b7**********29e
  227. redirect-uri: ${justauth.address}/social-callback?source=alipay_wallet
  228. alipay-public-key: MIIB**************DAQAB
  229. wechat_open:
  230. client-id: 10**********6
  231. client-secret: 1f7d08**********5b7**********29e
  232. redirect-uri: ${justauth.address}/social-callback?source=wechat_open
  233. wechat_mp:
  234. client-id: 10**********6
  235. client-secret: 1f7d08**********5b7**********29e
  236. redirect-uri: ${justauth.address}/social-callback?source=wechat_mp
  237. wechat_enterprise:
  238. client-id: 10**********6
  239. client-secret: 1f7d08**********5b7**********29e
  240. redirect-uri: ${justauth.address}/social-callback?source=wechat_enterprise
  241. agent-id: 1000002
  242. gitlab:
  243. client-id: 10**********6
  244. client-secret: 1f7d08**********5b7**********29e
  245. redirect-uri: ${justauth.address}/social-callback?source=gitlab