mirror of
https://gitee.com/dromara/RuoYi-Cloud-Plus.git
synced 2026-04-23 10:58:34 +08:00
update 更改整体配置策略 使用注册中心命名空间隔离
This commit is contained in:
@@ -1,135 +0,0 @@
|
||||
# redis 单机配置(单机与集群只能开启一个另一个需要注释掉)
|
||||
spring:
|
||||
datasource:
|
||||
system-master:
|
||||
driver-class-name: com.mysql.cj.jdbc.Driver
|
||||
url: jdbc:mysql://localhost:3306/ry-cloud?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
|
||||
username: root
|
||||
password: password
|
||||
gen:
|
||||
driver-class-name: com.mysql.cj.jdbc.Driver
|
||||
url: jdbc:mysql://localhost:3306/ry-cloud?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
|
||||
username: root
|
||||
password: password
|
||||
|
||||
# 多数据源配置
|
||||
dynamic:
|
||||
druid:
|
||||
initial-size: 5
|
||||
min-idle: 5
|
||||
maxActive: 20
|
||||
maxWait: 60000
|
||||
timeBetweenEvictionRunsMillis: 60000
|
||||
minEvictableIdleTimeMillis: 300000
|
||||
validationQuery: SELECT 1 FROM DUAL
|
||||
testWhileIdle: true
|
||||
testOnBorrow: false
|
||||
testOnReturn: false
|
||||
poolPreparedStatements: true
|
||||
maxPoolPreparedStatementPerConnectionSize: 20
|
||||
filters: stat,slf4j
|
||||
connectionProperties: druid.stat.mergeSql\=true;druid.stat.slowSqlMillis\=5000
|
||||
# seata: true # 开启seata代理,开启后默认每个数据源都代理,如果某个不需要代理可单独关闭
|
||||
|
||||
redis:
|
||||
# 地址
|
||||
host: localhost
|
||||
# 端口,默认为6379
|
||||
port: 6379
|
||||
# 数据库索引
|
||||
database: 0
|
||||
# 密码
|
||||
password:
|
||||
# 连接超时时间
|
||||
timeout: 10s
|
||||
# 是否开启ssl
|
||||
ssl: false
|
||||
|
||||
# redisson 配置
|
||||
redisson:
|
||||
# 线程池数量
|
||||
threads: 16
|
||||
# Netty线程池数量
|
||||
nettyThreads: 32
|
||||
# 传输模式
|
||||
transportMode: "NIO"
|
||||
# 单节点配置
|
||||
singleServerConfig:
|
||||
# 客户端名称
|
||||
clientName: ${ruoyi.name}
|
||||
# 最小空闲连接数
|
||||
connectionMinimumIdleSize: 32
|
||||
# 连接池大小
|
||||
connectionPoolSize: 64
|
||||
# 连接空闲超时,单位:毫秒
|
||||
idleConnectionTimeout: 10000
|
||||
# 命令等待超时,单位:毫秒
|
||||
timeout: 3000
|
||||
# 如果尝试在此限制之内发送成功,则开始启用 timeout 计时。
|
||||
retryAttempts: 3
|
||||
# 命令重试发送时间间隔,单位:毫秒
|
||||
retryInterval: 1500
|
||||
# 发布和订阅连接的最小空闲连接数
|
||||
subscriptionConnectionMinimumIdleSize: 1
|
||||
# 发布和订阅连接池大小
|
||||
subscriptionConnectionPoolSize: 50
|
||||
# 单个连接最大订阅数量
|
||||
subscriptionsPerConnection: 5
|
||||
# DNS监测时间间隔,单位:毫秒
|
||||
dnsMonitoringInterval: 5000
|
||||
|
||||
# seata配置
|
||||
seata:
|
||||
# 默认关闭,如需启用spring.datasource.dynami.seata需要同时开启
|
||||
enabled: false
|
||||
# Seata 应用编号,默认为 ${spring.application.name}
|
||||
application-id: ${spring.application.name}
|
||||
# Seata 事务组编号,用于 TC 集群名
|
||||
tx-service-group: ${spring.application.name}-group
|
||||
# 关闭自动代理
|
||||
enable-auto-data-source-proxy: false
|
||||
# 服务配置项
|
||||
service:
|
||||
# 虚拟组和分组的映射
|
||||
vgroup-mapping:
|
||||
ruoyi-system-group: default
|
||||
config:
|
||||
type: nacos
|
||||
nacos:
|
||||
serverAddr: ${spring.cloud.nacos.server-addr}
|
||||
group: SEATA_GROUP
|
||||
namespace:
|
||||
registry:
|
||||
type: nacos
|
||||
nacos:
|
||||
application: seata-server
|
||||
server-addr: ${spring.cloud.nacos.server-addr}
|
||||
namespace:
|
||||
|
||||
# 监控中心配置
|
||||
monitor:
|
||||
user:
|
||||
name: ruoyi
|
||||
password: 123456
|
||||
ui:
|
||||
title: RuoYi-Cloud-Plus服务监控中心
|
||||
|
||||
# 本地文件上传
|
||||
file:
|
||||
domain: http://127.0.0.1:9300
|
||||
path: D:/ruoyi/uploadPath
|
||||
prefix: /statics
|
||||
|
||||
# FastDFS配置
|
||||
fdfs:
|
||||
domain: http://8.129.231.12
|
||||
soTimeout: 3000
|
||||
connectTimeout: 2000
|
||||
trackerList: 8.129.231.12:22122
|
||||
|
||||
# Minio配置
|
||||
minio:
|
||||
url: http://8.129.231.12:9000
|
||||
accessKey: minioadmin
|
||||
secretKey: minioadmin
|
||||
bucketName: test
|
||||
@@ -1,135 +0,0 @@
|
||||
# redis 单机配置(单机与集群只能开启一个另一个需要注释掉)
|
||||
spring:
|
||||
datasource:
|
||||
system-master:
|
||||
driver-class-name: com.mysql.cj.jdbc.Driver
|
||||
url: jdbc:mysql://localhost:3306/ry-cloud?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
|
||||
username: root
|
||||
password: password
|
||||
gen:
|
||||
driver-class-name: com.mysql.cj.jdbc.Driver
|
||||
url: jdbc:mysql://localhost:3306/ry-cloud?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
|
||||
username: root
|
||||
password: password
|
||||
|
||||
# 多数据源配置
|
||||
dynamic:
|
||||
druid:
|
||||
initial-size: 5
|
||||
min-idle: 5
|
||||
maxActive: 20
|
||||
maxWait: 60000
|
||||
timeBetweenEvictionRunsMillis: 60000
|
||||
minEvictableIdleTimeMillis: 300000
|
||||
validationQuery: SELECT 1 FROM DUAL
|
||||
testWhileIdle: true
|
||||
testOnBorrow: false
|
||||
testOnReturn: false
|
||||
poolPreparedStatements: true
|
||||
maxPoolPreparedStatementPerConnectionSize: 20
|
||||
filters: stat,slf4j
|
||||
connectionProperties: druid.stat.mergeSql\=true;druid.stat.slowSqlMillis\=5000
|
||||
# seata: true # 开启seata代理,开启后默认每个数据源都代理,如果某个不需要代理可单独关闭
|
||||
|
||||
redis:
|
||||
# 地址
|
||||
host: localhost
|
||||
# 端口,默认为6379
|
||||
port: 6379
|
||||
# 数据库索引
|
||||
database: 0
|
||||
# 密码
|
||||
password:
|
||||
# 连接超时时间
|
||||
timeout: 10s
|
||||
# 是否开启ssl
|
||||
ssl: false
|
||||
|
||||
# redisson 配置
|
||||
redisson:
|
||||
# 线程池数量
|
||||
threads: 16
|
||||
# Netty线程池数量
|
||||
nettyThreads: 32
|
||||
# 传输模式
|
||||
transportMode: "NIO"
|
||||
# 单节点配置
|
||||
singleServerConfig:
|
||||
# 客户端名称
|
||||
clientName: ${ruoyi.name}
|
||||
# 最小空闲连接数
|
||||
connectionMinimumIdleSize: 32
|
||||
# 连接池大小
|
||||
connectionPoolSize: 64
|
||||
# 连接空闲超时,单位:毫秒
|
||||
idleConnectionTimeout: 10000
|
||||
# 命令等待超时,单位:毫秒
|
||||
timeout: 3000
|
||||
# 如果尝试在此限制之内发送成功,则开始启用 timeout 计时。
|
||||
retryAttempts: 3
|
||||
# 命令重试发送时间间隔,单位:毫秒
|
||||
retryInterval: 1500
|
||||
# 发布和订阅连接的最小空闲连接数
|
||||
subscriptionConnectionMinimumIdleSize: 1
|
||||
# 发布和订阅连接池大小
|
||||
subscriptionConnectionPoolSize: 50
|
||||
# 单个连接最大订阅数量
|
||||
subscriptionsPerConnection: 5
|
||||
# DNS监测时间间隔,单位:毫秒
|
||||
dnsMonitoringInterval: 5000
|
||||
|
||||
# seata配置
|
||||
seata:
|
||||
# 默认关闭,如需启用spring.datasource.dynami.seata需要同时开启
|
||||
enabled: false
|
||||
# Seata 应用编号,默认为 ${spring.application.name}
|
||||
application-id: ${spring.application.name}
|
||||
# Seata 事务组编号,用于 TC 集群名
|
||||
tx-service-group: ${spring.application.name}-group
|
||||
# 关闭自动代理
|
||||
enable-auto-data-source-proxy: false
|
||||
# 服务配置项
|
||||
service:
|
||||
# 虚拟组和分组的映射
|
||||
vgroup-mapping:
|
||||
ruoyi-system-group: default
|
||||
config:
|
||||
type: nacos
|
||||
nacos:
|
||||
serverAddr: ${spring.cloud.nacos.server-addr}
|
||||
group: SEATA_GROUP
|
||||
namespace:
|
||||
registry:
|
||||
type: nacos
|
||||
nacos:
|
||||
application: seata-server
|
||||
server-addr: ${spring.cloud.nacos.server-addr}
|
||||
namespace:
|
||||
|
||||
# 监控中心配置
|
||||
monitor:
|
||||
user:
|
||||
name: ruoyi
|
||||
password: 123456
|
||||
ui:
|
||||
title: RuoYi-Cloud-Plus服务监控中心
|
||||
|
||||
# 本地文件上传
|
||||
file:
|
||||
domain: http://127.0.0.1:9300
|
||||
path: D:/ruoyi/uploadPath
|
||||
prefix: /statics
|
||||
|
||||
# FastDFS配置
|
||||
fdfs:
|
||||
domain: http://8.129.231.12
|
||||
soTimeout: 3000
|
||||
connectTimeout: 2000
|
||||
trackerList: 8.129.231.12:22122
|
||||
|
||||
# Minio配置
|
||||
minio:
|
||||
url: http://8.129.231.12:9000
|
||||
accessKey: minioadmin
|
||||
secretKey: minioadmin
|
||||
bucketName: test
|
||||
@@ -26,6 +26,8 @@ dubbo:
|
||||
registry:
|
||||
address: nacos://${spring.cloud.nacos.server-addr}
|
||||
group: DUBBO_GROUP
|
||||
# URL采用精简模式(与元数据中心配合)
|
||||
simplified: true
|
||||
# 消费者相关配置
|
||||
consumer:
|
||||
# 结果缓存(LRU算法)
|
||||
@@ -53,107 +55,63 @@ spring:
|
||||
date-format: yyyy-MM-dd HH:mm:ss
|
||||
serialization:
|
||||
# 格式化输出
|
||||
indent_output: false
|
||||
INDENT_OUTPUT: false
|
||||
# 忽略无法转换的对象
|
||||
fail_on_empty_beans: false
|
||||
deserialization:
|
||||
# 允许对象忽略json中不存在的属性
|
||||
fail_on_unknown_properties: false
|
||||
cloud:
|
||||
# 网关配置
|
||||
gateway:
|
||||
discovery:
|
||||
locator:
|
||||
lowerCaseServiceId: true
|
||||
enabled: true
|
||||
routes:
|
||||
# 认证中心
|
||||
- id: ruoyi-auth
|
||||
uri: lb://ruoyi-auth
|
||||
predicates:
|
||||
- Path=/auth/**
|
||||
filters:
|
||||
# 验证码处理
|
||||
- CacheRequestFilter
|
||||
- ValidateCodeFilter
|
||||
- StripPrefix=1
|
||||
# 代码生成
|
||||
- id: ruoyi-gen
|
||||
uri: lb://ruoyi-gen
|
||||
predicates:
|
||||
- Path=/code/**
|
||||
filters:
|
||||
- StripPrefix=1
|
||||
# 定时任务
|
||||
- id: ruoyi-job
|
||||
uri: lb://ruoyi-job
|
||||
predicates:
|
||||
- Path=/schedule/**
|
||||
filters:
|
||||
- StripPrefix=1
|
||||
# 系统模块
|
||||
- id: ruoyi-system
|
||||
uri: lb://ruoyi-system
|
||||
predicates:
|
||||
- Path=/system/**
|
||||
filters:
|
||||
- StripPrefix=1
|
||||
# 文件服务
|
||||
- id: ruoyi-file
|
||||
uri: lb://ruoyi-file
|
||||
predicates:
|
||||
- Path=/file/**
|
||||
filters:
|
||||
- StripPrefix=1
|
||||
# sentinel 配置
|
||||
sentinel:
|
||||
# 取消控制台懒加载
|
||||
eager: true
|
||||
transport:
|
||||
# 控制台地址
|
||||
dashboard: localhost:8718
|
||||
|
||||
# 安全配置
|
||||
security:
|
||||
# 验证码
|
||||
captcha:
|
||||
# 是否开启验证码
|
||||
enabled: true
|
||||
# 验证码类型 math 数组计算 char 字符验证
|
||||
type: MATH
|
||||
# line 线段干扰 circle 圆圈干扰 shear 扭曲干扰
|
||||
category: CIRCLE
|
||||
# 数字验证码位数
|
||||
numberLength: 1
|
||||
# 字符验证码长度
|
||||
charLength: 4
|
||||
# 防止XSS攻击
|
||||
xss:
|
||||
enabled: true
|
||||
excludeUrls:
|
||||
- /system/notice
|
||||
# 不校验白名单
|
||||
ignore:
|
||||
whites:
|
||||
- /auth/logout
|
||||
- /auth/login
|
||||
- /auth/register
|
||||
- /*/v2/api-docs
|
||||
- /csrf
|
||||
# redis通用配置 子服务可以自行配置进行覆盖
|
||||
redis:
|
||||
host: localhost
|
||||
port: 6379
|
||||
password:
|
||||
database: 0
|
||||
timeout: 10s
|
||||
ssl: false
|
||||
|
||||
# 暴露监控端点
|
||||
management:
|
||||
endpoints:
|
||||
web:
|
||||
exposure:
|
||||
include: '*'
|
||||
endpoint:
|
||||
logfile:
|
||||
external-file: ./logs/${spring.application.name}/console.log
|
||||
|
||||
# 日志配置
|
||||
logging:
|
||||
level:
|
||||
org.springframework: warn
|
||||
org.apache.dubbo: warn
|
||||
com.alibaba.nacos: warn
|
||||
config: classpath:logback.xml
|
||||
|
||||
# redisson 缓存配置
|
||||
# redisson 配置
|
||||
redisson:
|
||||
# 线程池数量
|
||||
threads: 16
|
||||
# Netty线程池数量
|
||||
nettyThreads: 32
|
||||
# 传输模式
|
||||
transportMode: "NIO"
|
||||
# 单节点配置
|
||||
singleServerConfig:
|
||||
# 客户端名称
|
||||
clientName: ${ruoyi.name}
|
||||
# 最小空闲连接数
|
||||
connectionMinimumIdleSize: 32
|
||||
# 连接池大小
|
||||
connectionPoolSize: 64
|
||||
# 连接空闲超时,单位:毫秒
|
||||
idleConnectionTimeout: 10000
|
||||
# 命令等待超时,单位:毫秒
|
||||
timeout: 3000
|
||||
# 如果尝试在此限制之内发送成功,则开始启用 timeout 计时。
|
||||
retryAttempts: 3
|
||||
# 命令重试发送时间间隔,单位:毫秒
|
||||
retryInterval: 1500
|
||||
# 发布和订阅连接的最小空闲连接数
|
||||
subscriptionConnectionMinimumIdleSize: 1
|
||||
# 发布和订阅连接池大小
|
||||
subscriptionConnectionPoolSize: 50
|
||||
# 单个连接最大订阅数量
|
||||
subscriptionsPerConnection: 5
|
||||
# DNS监测时间间隔,单位:毫秒
|
||||
dnsMonitoringInterval: 5000
|
||||
# redisson 缓存配置
|
||||
cacheGroup:
|
||||
# 用例: @Cacheable(cacheNames="groupId", key="#XXX") 方可使用缓存组配置
|
||||
- groupId: redissonCacheMap
|
||||
@@ -171,6 +129,26 @@ lock4j:
|
||||
# 分布式锁的超时时间,默认为 30 毫秒
|
||||
expire: 30000
|
||||
|
||||
# 暴露监控端点
|
||||
management:
|
||||
endpoints:
|
||||
web:
|
||||
exposure:
|
||||
include: '*'
|
||||
endpoint:
|
||||
health:
|
||||
show-details: ALWAYS
|
||||
logfile:
|
||||
external-file: ./logs/${spring.application.name}/console.log
|
||||
|
||||
# 日志配置
|
||||
logging:
|
||||
level:
|
||||
org.springframework: warn
|
||||
org.apache.dubbo: warn
|
||||
com.alibaba.nacos: warn
|
||||
config: classpath:logback.xml
|
||||
|
||||
# mybatis配置
|
||||
mybatis:
|
||||
# 搜索指定包别名
|
||||
@@ -182,3 +160,29 @@ mybatis:
|
||||
swagger:
|
||||
license: Powered By ruoyi
|
||||
licenseUrl: https://ruoyi.vip
|
||||
|
||||
# seata配置
|
||||
seata:
|
||||
# 默认关闭,如需启用spring.datasource.dynami.seata需要同时开启
|
||||
enabled: false
|
||||
# Seata 应用编号,默认为 ${spring.application.name}
|
||||
application-id: ${spring.application.name}
|
||||
# Seata 事务组编号,用于 TC 集群名
|
||||
tx-service-group: ${spring.application.name}-group
|
||||
# 服务配置项
|
||||
service:
|
||||
# 虚拟组和分组的映射
|
||||
vgroup-mapping:
|
||||
${spring.application.name}: default
|
||||
config:
|
||||
type: nacos
|
||||
nacos:
|
||||
serverAddr: ${spring.cloud.nacos.server-addr}
|
||||
group: SEATA_GROUP
|
||||
namespace:
|
||||
registry:
|
||||
type: nacos
|
||||
nacos:
|
||||
application: seata-server
|
||||
server-addr: ${spring.cloud.nacos.server-addr}
|
||||
namespace:
|
||||
41
config/dev/datasource.yml
Normal file
41
config/dev/datasource.yml
Normal file
@@ -0,0 +1,41 @@
|
||||
datasource:
|
||||
system-master:
|
||||
# jdbc 所有参数配置参考 https://lionli.blog.csdn.net/article/details/122018562
|
||||
# rewriteBatchedStatements=true 批处理优化 大幅提升批量插入更新删除性能
|
||||
url: jdbc:mysql://localhost:3306/ry-cloud?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8&rewriteBatchedStatements=true
|
||||
username: root
|
||||
password: password
|
||||
gen:
|
||||
url: jdbc:mysql://localhost:3306/ry-cloud?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8&rewriteBatchedStatements=true
|
||||
username: root
|
||||
password: password
|
||||
|
||||
spring:
|
||||
datasource:
|
||||
type: com.alibaba.druid.pool.DruidDataSource
|
||||
# 动态数据源文档 https://www.kancloud.cn/tracy5546/dynamic-datasource/content
|
||||
dynamic:
|
||||
# 性能分析插件(有性能损耗 不建议生产环境使用)
|
||||
p6spy: false
|
||||
# 开启seata代理,开启后默认每个数据源都代理,如果某个不需要代理可单独关闭
|
||||
seata: false
|
||||
druid:
|
||||
initial-size: 5
|
||||
min-idle: 5
|
||||
maxActive: 20
|
||||
maxWait: 60000
|
||||
timeBetweenEvictionRunsMillis: 60000
|
||||
minEvictableIdleTimeMillis: 300000
|
||||
validationQuery: SELECT 1 FROM DUAL
|
||||
testWhileIdle: true
|
||||
testOnBorrow: false
|
||||
testOnReturn: false
|
||||
poolPreparedStatements: true
|
||||
maxPoolPreparedStatementPerConnectionSize: 20
|
||||
filters: stat,slf4j
|
||||
connectionProperties: druid.stat.mergeSql\=true;druid.stat.slowSqlMillis\=5000
|
||||
|
||||
# seata配置
|
||||
seata:
|
||||
# 关闭自动代理
|
||||
enable-auto-data-source-proxy: false
|
||||
5
config/dev/ruoyi-auth.yml
Normal file
5
config/dev/ruoyi-auth.yml
Normal file
@@ -0,0 +1,5 @@
|
||||
# dubbo 订阅配置
|
||||
dubbo:
|
||||
cloud:
|
||||
# 需要远程调用的服务 多个用逗号分割
|
||||
subscribed-services: ruoyi-system
|
||||
25
config/dev/ruoyi-file.yml
Normal file
25
config/dev/ruoyi-file.yml
Normal file
@@ -0,0 +1,25 @@
|
||||
# dubbo 订阅配置
|
||||
dubbo:
|
||||
cloud:
|
||||
# 需要远程调用的服务 多个用逗号分割
|
||||
subscribed-services: ruoyi-system
|
||||
|
||||
# 本地文件上传
|
||||
file:
|
||||
domain: http://127.0.0.1:9300
|
||||
path: D:/ruoyi/uploadPath
|
||||
prefix: /statics
|
||||
|
||||
# FastDFS配置
|
||||
fdfs:
|
||||
domain: http://8.129.231.12
|
||||
soTimeout: 3000
|
||||
connectTimeout: 2000
|
||||
trackerList: 8.129.231.12:22122
|
||||
|
||||
# Minio配置
|
||||
minio:
|
||||
url: http://8.129.231.12:9000
|
||||
accessKey: minioadmin
|
||||
secretKey: minioadmin
|
||||
bucketName: test
|
||||
93
config/dev/ruoyi-gateway.yml
Normal file
93
config/dev/ruoyi-gateway.yml
Normal file
@@ -0,0 +1,93 @@
|
||||
# dubbo 订阅配置
|
||||
dubbo:
|
||||
cloud:
|
||||
# 需要远程调用的服务 多个用逗号分割
|
||||
subscribed-services: ruoyi-auth,ruoyi-system
|
||||
|
||||
# 安全配置
|
||||
security:
|
||||
# 验证码
|
||||
captcha:
|
||||
# 是否开启验证码
|
||||
enabled: true
|
||||
# 验证码类型 math 数组计算 char 字符验证
|
||||
type: MATH
|
||||
# line 线段干扰 circle 圆圈干扰 shear 扭曲干扰
|
||||
category: CIRCLE
|
||||
# 数字验证码位数
|
||||
numberLength: 1
|
||||
# 字符验证码长度
|
||||
charLength: 4
|
||||
# 防止XSS攻击
|
||||
xss:
|
||||
enabled: true
|
||||
excludeUrls:
|
||||
- /system/notice
|
||||
# 不校验白名单
|
||||
ignore:
|
||||
whites:
|
||||
- /auth/logout
|
||||
- /auth/login
|
||||
- /auth/register
|
||||
- /*/v2/api-docs
|
||||
- /csrf
|
||||
|
||||
spring:
|
||||
cloud:
|
||||
# 网关配置
|
||||
gateway:
|
||||
discovery:
|
||||
locator:
|
||||
lowerCaseServiceId: true
|
||||
enabled: true
|
||||
routes:
|
||||
# 认证中心
|
||||
- id: ruoyi-auth
|
||||
uri: lb://ruoyi-auth
|
||||
predicates:
|
||||
- Path=/auth/**
|
||||
filters:
|
||||
# 验证码处理
|
||||
- CacheRequestFilter
|
||||
- ValidateCodeFilter
|
||||
- StripPrefix=1
|
||||
# 代码生成
|
||||
- id: ruoyi-gen
|
||||
uri: lb://ruoyi-gen
|
||||
predicates:
|
||||
- Path=/code/**
|
||||
filters:
|
||||
- StripPrefix=1
|
||||
# 定时任务
|
||||
- id: ruoyi-job
|
||||
uri: lb://ruoyi-job
|
||||
predicates:
|
||||
- Path=/schedule/**
|
||||
filters:
|
||||
- StripPrefix=1
|
||||
# 系统模块
|
||||
- id: ruoyi-system
|
||||
uri: lb://ruoyi-system
|
||||
predicates:
|
||||
- Path=/system/**
|
||||
filters:
|
||||
- StripPrefix=1
|
||||
# 文件服务
|
||||
- id: ruoyi-file
|
||||
uri: lb://ruoyi-file
|
||||
predicates:
|
||||
- Path=/file/**
|
||||
filters:
|
||||
- StripPrefix=1
|
||||
|
||||
# sentinel 配置
|
||||
sentinel:
|
||||
# nacos配置持久化
|
||||
datasource:
|
||||
ds1:
|
||||
nacos:
|
||||
server-addr: ${spring.cloud.nacos.server-addr}
|
||||
dataId: sentinel-${spring.application.name}
|
||||
groupId: ${spring.cloud.nacos.config.group}
|
||||
data-type: json
|
||||
rule-type: flow
|
||||
40
config/dev/ruoyi-gen.yml
Normal file
40
config/dev/ruoyi-gen.yml
Normal file
@@ -0,0 +1,40 @@
|
||||
# dubbo 订阅配置
|
||||
dubbo:
|
||||
cloud:
|
||||
# 需要远程调用的服务 多个用逗号分割
|
||||
subscribed-services: ruoyi-system
|
||||
|
||||
# swagger配置
|
||||
swagger:
|
||||
title: 代码生成接口文档
|
||||
|
||||
spring:
|
||||
datasource:
|
||||
dynamic:
|
||||
# 设置默认的数据源或者数据源组,默认值即为 master
|
||||
primary: master
|
||||
datasource:
|
||||
# 主库数据源
|
||||
master:
|
||||
driver-class-name: com.mysql.cj.jdbc.Driver
|
||||
url: ${datasource.system-master.url}
|
||||
username: ${datasource.system-master.username}
|
||||
password: ${datasource.system-master.password}
|
||||
# 从库数据源
|
||||
slave:
|
||||
lazy: true
|
||||
driver-class-name:
|
||||
url:
|
||||
username:
|
||||
password:
|
||||
|
||||
# 代码生成
|
||||
gen:
|
||||
# 作者
|
||||
author: ruoyi
|
||||
# 默认生成包路径 system 需改成自己的模块名称 如 system monitor tool
|
||||
packageName: com.ruoyi.system
|
||||
# 自动去除表前缀,默认是false
|
||||
autoRemovePre: false
|
||||
# 表前缀(生成类名不会包含表前缀,多个用逗号分隔)
|
||||
tablePrefix: sys_
|
||||
0
config/dev/ruoyi-job.yml
Normal file
0
config/dev/ruoyi-job.yml
Normal file
7
config/dev/ruoyi-monitor.yml
Normal file
7
config/dev/ruoyi-monitor.yml
Normal file
@@ -0,0 +1,7 @@
|
||||
# 监控中心配置
|
||||
monitor:
|
||||
user:
|
||||
name: ruoyi
|
||||
password: 123456
|
||||
ui:
|
||||
title: RuoYi-Cloud-Plus服务监控中心
|
||||
29
config/dev/ruoyi-system.yml
Normal file
29
config/dev/ruoyi-system.yml
Normal file
@@ -0,0 +1,29 @@
|
||||
# dubbo 订阅配置
|
||||
dubbo:
|
||||
cloud:
|
||||
# 需要远程调用的服务 多个用逗号分割
|
||||
subscribed-services: ruoyi-file
|
||||
|
||||
# swagger配置
|
||||
swagger:
|
||||
title: 系统模块接口文档
|
||||
|
||||
spring:
|
||||
datasource:
|
||||
dynamic:
|
||||
# 设置默认的数据源或者数据源组,默认值即为 master
|
||||
primary: master
|
||||
datasource:
|
||||
# 主库数据源
|
||||
master:
|
||||
driver-class-name: com.mysql.cj.jdbc.Driver
|
||||
url: ${datasource.system-master.url}
|
||||
username: ${datasource.system-master.username}
|
||||
password: ${datasource.system-master.password}
|
||||
# 从库数据源
|
||||
slave:
|
||||
lazy: true
|
||||
driver-class-name:
|
||||
url:
|
||||
username:
|
||||
password:
|
||||
Reference in New Issue
Block a user