application-prod.yml 8.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227
  1. # 项目相关配置
  2. boman:
  3. # 文件路径 示例( Windows配置D:/ruoyi/uploadPath,Linux配置 /home/ruoyi/uploadPath)
  4. profile: /home/ruoyi/uploadPath/wuye
  5. passwordDeft: 1qaz!QAZ
  6. --- # 临时文件存储位置 避免临时文件被系统清理报错
  7. spring.servlet.multipart.location: /ruoyi/server/temp
  8. --- # 监控中心配置
  9. spring.boot.admin.client:
  10. # 增加客户端开关
  11. enabled: false
  12. url: http://localhost:9090/admin
  13. instance:
  14. service-host-type: IP
  15. metadata:
  16. username: ${spring.boot.admin.client.username}
  17. userpassword: ${spring.boot.admin.client.password}
  18. username: @monitor.username@
  19. password: @monitor.password@
  20. --- # snail-job 配置
  21. snail-job:
  22. enabled: false
  23. # 需要在 SnailJob 后台组管理创建对应名称的组,然后创建任务的时候选择对应的组,才能正确分派任务
  24. group: "ruoyi_group"
  25. # SnailJob 接入验证令牌 详见 script/sql/ry_job.sql `sj_group_config`表
  26. token: "SJ_cKqBTPzCsWA3VyuCfFoccmuIEGXjr5KT"
  27. server:
  28. host: 127.0.0.1
  29. port: 17888
  30. # 命名空间UUID 详见 script/sql/ry_job.sql `sj_namespace`表`unique_id`字段
  31. namespace: ${spring.profiles.active}
  32. # 随主应用端口漂移
  33. port: 2${server.port}
  34. # 客户端ip指定
  35. host:
  36. # RPC类型: netty, grpc
  37. rpc-type: grpc
  38. --- # 数据源配置
  39. spring:
  40. datasource:
  41. type: com.zaxxer.hikari.HikariDataSource
  42. # 动态数据源文档 https://www.kancloud.cn/tracy5546/dynamic-datasource/content
  43. dynamic:
  44. # 性能分析插件(有性能损耗 不建议生产环境使用)
  45. p6spy: false
  46. # 设置默认的数据源或者数据源组,默认值即为 master
  47. primary: master
  48. # 严格模式 匹配不到数据源则报错
  49. strict: true
  50. datasource:
  51. # 主库数据源
  52. master:
  53. type: ${spring.datasource.type}
  54. driverClassName: com.mysql.cj.jdbc.Driver
  55. # jdbc 所有参数配置参考 https://lionli.blog.csdn.net/article/details/122018562
  56. # rewriteBatchedStatements=true 批处理优化 大幅提升批量插入更新删除性能(对数据库有性能损耗 使用批量操作应考虑性能问题)
  57. url: jdbc:mysql://localhost:3306/ry-vue?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8&autoReconnect=true&rewriteBatchedStatements=true&allowPublicKeyRetrieval=true&nullCatalogMeansCurrent=true
  58. username: root
  59. password: root
  60. # # 从库数据源
  61. # slave:
  62. # lazy: true
  63. # type: ${spring.datasource.type}
  64. # driverClassName: com.mysql.cj.jdbc.Driver
  65. # url: jdbc:mysql://localhost:3306/ry-vue?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8&autoReconnect=true&rewriteBatchedStatements=true&allowPublicKeyRetrieval=true&nullCatalogMeansCurrent=true
  66. # username:
  67. # password:
  68. # oracle:
  69. # type: ${spring.datasource.type}
  70. # driverClassName: oracle.jdbc.OracleDriver
  71. # url: jdbc:oracle:thin:@//localhost:1521/XE
  72. # username: ROOT
  73. # password: root
  74. # postgres:
  75. # type: ${spring.datasource.type}
  76. # driverClassName: org.postgresql.Driver
  77. # url: jdbc:postgresql://localhost:5432/postgres?useUnicode=true&characterEncoding=utf8&useSSL=true&autoReconnect=true&reWriteBatchedInserts=true
  78. # username: root
  79. # password: root
  80. # sqlserver:
  81. # type: ${spring.datasource.type}
  82. # driverClassName: com.microsoft.sqlserver.jdbc.SQLServerDriver
  83. # url: jdbc:sqlserver://localhost:1433;DatabaseName=tempdb;SelectMethod=cursor;encrypt=false;rewriteBatchedStatements=true
  84. # username: SA
  85. # password: root
  86. hikari:
  87. # 最大连接池数量
  88. maxPoolSize: 20
  89. # 最小空闲线程数量
  90. minIdle: 10
  91. # 配置获取连接等待超时的时间
  92. connectionTimeout: 30000
  93. # 校验超时时间
  94. validationTimeout: 5000
  95. # 空闲连接存活最大时间,默认10分钟
  96. idleTimeout: 600000
  97. # 此属性控制池中连接的最长生命周期,值0表示无限生命周期,默认30分钟
  98. maxLifetime: 1800000
  99. # 多久检查一次连接的活性
  100. keepaliveTime: 30000
  101. --- # redis 单机配置(单机与集群只能开启一个另一个需要注释掉)
  102. spring.data:
  103. redis:
  104. # 地址
  105. host: localhost
  106. # 端口,默认为6379
  107. port: 6379
  108. # 数据库索引
  109. database: 0
  110. # redis 密码必须配置
  111. password: ruoyi123
  112. # 连接超时时间
  113. timeout: 10s
  114. # 是否开启ssl
  115. ssl.enabled: false
  116. # redisson 配置
  117. redisson:
  118. # redis key前缀
  119. keyPrefix:
  120. # 线程池数量
  121. threads: 16
  122. # Netty线程池数量
  123. nettyThreads: 32
  124. # 单节点配置
  125. singleServerConfig:
  126. # 客户端名称 不能用中文
  127. clientName: RuoYi-Vue-Plus
  128. # 最小空闲连接数
  129. connectionMinimumIdleSize: 32
  130. # 连接池大小
  131. connectionPoolSize: 64
  132. # 连接空闲超时,单位:毫秒
  133. idleConnectionTimeout: 10000
  134. # 命令等待超时,单位:毫秒
  135. timeout: 3000
  136. # 发布和订阅连接池大小
  137. subscriptionConnectionPoolSize: 50
  138. --- # mail 邮件发送
  139. mail:
  140. enabled: false
  141. host: smtp.163.com
  142. port: 465
  143. # 是否需要用户名密码验证
  144. auth: true
  145. # 发送方,遵循RFC-822标准
  146. from: xxx@163.com
  147. # 用户名(注意:如果使用foxmail邮箱,此处user为qq号)
  148. user: xxx@163.com
  149. # 密码(注意,某些邮箱需要为SMTP服务单独设置密码,详情查看相关帮助)
  150. pass: xxxxxxxxxx
  151. # 使用 STARTTLS安全连接,STARTTLS是对纯文本通信协议的扩展。
  152. starttlsEnable: true
  153. # 使用SSL安全连接
  154. sslEnable: true
  155. # SMTP超时时长,单位毫秒,缺省值不超时
  156. timeout: 0
  157. # Socket连接超时值,单位毫秒,缺省值不超时
  158. connectionTimeout: 0
  159. --- # sms 短信 支持 阿里云 腾讯云 云片 等等各式各样的短信服务商
  160. # https://sms4j.com/doc3/ 差异配置文档地址 支持单厂商多配置,可以配置多个同时使用
  161. sms:
  162. # 配置源类型用于标定配置来源(interface,yaml)
  163. config-type: yaml
  164. # 用于标定yml中的配置是否开启短信拦截,接口配置不受此限制
  165. restricted: true
  166. # 短信拦截限制单手机号每分钟最大发送,只对开启了拦截的配置有效
  167. minute-max: 5
  168. # 短信拦截限制单手机号每日最大发送量,只对开启了拦截的配置有效
  169. account-max: 30
  170. # 以下配置来自于 org.dromara.sms4j.provider.config.BaseConfig类中
  171. blends:
  172. # 唯一ID 用于发送短信寻找具体配置 随便定义别用中文即可
  173. # 可以同时存在两个相同厂商 例如: ali1 ali2 两个不同的阿里短信账号 也可用于区分租户
  174. config1:
  175. # 框架定义的厂商名称标识,标定此配置是哪个厂商,详细请看厂商标识介绍部分
  176. supplier: alibaba
  177. # 有些称为accessKey有些称之为apiKey,也有称为sdkKey或者appId。
  178. access-key-id: 您的accessKey
  179. # 称为accessSecret有些称之为apiSecret
  180. access-key-secret: 您的accessKeySecret
  181. signature: 您的短信签名
  182. sdk-app-id: 您的sdkAppId
  183. # config2:
  184. # # 厂商标识,标定此配置是哪个厂商,详细请看厂商标识介绍部分
  185. # supplier: tencent
  186. # access-key-id: 您的accessKey
  187. # access-key-secret: 您的accessKeySecret
  188. # signature: 您的短信签名
  189. # sdk-app-id: 您的sdkAppId
  190. --- # 三方授权
  191. justauth:
  192. # 前端外网访问地址
  193. address: http://localhost:80
  194. type:
  195. maxkey:
  196. # maxkey 服务器地址
  197. # 注意 如下均配置均不需要修改 maxkey 已经内置好了数据
  198. server-url: http://sso.maxkey.top
  199. client-id: 876892492581044224
  200. client-secret: x1Y5MTMwNzIwMjMxNTM4NDc3Mzche8
  201. redirect-uri: ${justauth.address}/social-callback?source=maxkey
  202. alipay_wallet:
  203. client-id: 10**********6
  204. client-secret: 1f7d08**********5b7**********29e
  205. redirect-uri: ${justauth.address}/social-callback?source=alipay_wallet
  206. alipay-public-key: MIIB**************DAQAB
  207. wechat_open:
  208. client-id: 10**********6
  209. client-secret: 1f7d08**********5b7**********29e
  210. redirect-uri: ${justauth.address}/social-callback?source=wechat_open
  211. wechat_mp:
  212. client-id: 10**********6
  213. client-secret: 1f7d08**********5b7**********29e
  214. redirect-uri: ${justauth.address}/social-callback?source=wechat_mp
  215. wechat_enterprise:
  216. client-id: 10**********6
  217. client-secret: 1f7d08**********5b7**********29e
  218. redirect-uri: ${justauth.address}/social-callback?source=wechat_enterprise
  219. agent-id: 1000002