You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

169 lines
5.1 KiB

server:
port: 8011
# 项目配置
nl:
config:
mysql:
ip: 127.0.0.1
port: 3306
username: root
password: 12356
database: nl-platform
redis:
ip: 127.0.0.1
port: 6379
password: null
database: 1
oracle:
ip: 172.27.37.66
port: 1521
scheme: RTMES
username: LMSTELCOM
password: LMSTELCOM_6463
sqlserver:
ip: 10.93.41.2
port: WINCC
username: sa
password: 123
database: 马钢_RH
# 配置数据源
spring:
autoconfigure:
exclude: com.alibaba.druid.spring.boot.autoconfigure.DruidDataSourceAutoConfigure
datasource:
dynamic:
primary: mysql
datasource:
mysql:
driver-class-name: net.sf.log4jdbc.sql.jdbcapi.DriverSpy
url: jdbc:log4jdbc:mysql://${DB_HOST:${nl.config.mysql.ip}}:${DB_PORT:${nl.config.mysql.port}}/${DB_NAME:${nl.config.mysql.database}}?serverTimezone=Asia/Shanghai&characterEncoding=utf8&useSSL=false&useOldAliasMetadataBehavior=true
username: ${DB_USER:${nl.config.mysql.username}}
password: ${DB_PWD:${nl.config.mysql.password}}
type: com.alibaba.druid.pool.DruidDataSource
oracle:
driver-class-name: oracle.jdbc.OracleDriver
url: jdbc:oracle:thin:@${nl.config.oracle.ip}:${nl.config.oracle.port}:${nl.config.oracle.scheme}
username: ${DB_USER:${nl.config.oracle.username}}
password: ${DB_PWD:${nl.config.oracle.password}}
type: com.alibaba.druid.pool.DruidDataSource
sqlserver:
driver-class-name: com.microsoft.sqlserver.jdbc.SQLServerDriver
url: jdbc:sqlserver://${nl.config.sqlserver.ip}\${nl.config.sqlserver.port};DatabaseName=${nl.config.sqlserver.database}
username: ${DB_USER:${nl.config.sqlserver.username}}
password: ${DB_PWD:${nl.config.sqlserver.password}}
type: com.alibaba.druid.pool.DruidDataSource
redis:
# 数据库索引
host: ${REDIS_HOST:${nl.config.redis.ip}}
port: ${REDIS_PORT:${nl.config.redis.port}}
password: ${REDIS_PWD:${nl.config.redis.password}}
redisson:
config: |
threads: 4
nettyThreads: 4
singleServerConfig:
database: 3
connectionMinimumIdleSize: 8
connectionPoolSize: 8
address: redis://127.0.0.1:6379
idleConnectionTimeout: 10000
timeout: 3000
jetcache:
statIntervalMinutes: 15
areaInCacheName: false
local:
default:
type: linkedhashmap
keyConvertor: fastjson
remote:
default:
type: redis
keyConvertor: fastjson2
broadcastChannel: projectA
valueEncoder: java
valueDecoder: java
poolConfig:
minIdle: 5
maxIdle: 20
maxTotal: 50
host: ${nl.config.redis.ip}
port: ${nl.config.redis.port}
#是否允许生成代码,生产环境设置为false
generator:
enabled: true
# IP 本地解析
ip:
local-parsing: true
# 文件存储路径
file:
mac:
path: ~/file/
avatar: ~/avatar/
linux:
path: /home/eladmin/file/
avatar: /home/eladmin/avatar/
windows:
path: C:\eladmin\file\
avatar: C:\eladmin\avatar\
# 文件大小 /M
maxSize: 100
avatarMaxSize: 5
logging:
file:
path: C:\log\wms
config: classpath:logback-spring.xml
# Sa-Token配置
sa-token:
# token 名称 (同时也是cookie名称)
token-name: Authorization
# token 有效期,单位s 默认30天, -1代表永不过期
timeout: 2592000
# token 临时有效期 (指定时间内无操作就视为token过期) 单位: 秒
activity-timeout: -1
# 是否允许同一账号并发登录 (为true时允许一起登录, 为false时新登录挤掉旧登录)
is-concurrent: true
# 在多人登录同一账号时,是否共用一个token (为true时所有登录共用一个token, 为false时每次登录新建一个token)
is-share: false
# token风格
token-style: random-128
# 是否输出操作日志
is-log: false
jwt-secret-key: opsjajisdnnca0sdkksdfaaasdfwwq
# token 前缀
token-prefix: Bearer
sso:
# Ticket有效期 (单位: 秒),默认五分钟
ticket-timeout: 300
# 所有允许的授权回调地址
allow-url: "*"
# 是否打开单点注销功能
is-slo: true
# ------- SSO-模式三相关配置 (下面的配置在SSO模式三并且 is-slo=true 时打开)
# 是否打开模式三
isHttp: true
# 接口调用秘钥(用于SSO模式三的单点注销功能)
secretkey: kQwIOrYvnXmSDkwEiFngrKidMcdrgKor
# ---- 除了以上配置项,你还需要为 Sa-Token 配置http请求处理器(文档有步骤说明)
is-read-cookie: true
is-print: false
# 未登录 StpUtil.getTokenSession() 设置值,获取值 @SaIgnore 得忽略接口
token-session-check-login: false
alone-redis:
# Redis数据库索引(默认为0)
database: ${nl.config.redis.database}
# Redis服务器地址
host: ${nl.config.redis.ip}
# Redis服务器连接端口
port: ${nl.config.redis.port}
# Redis服务器连接密码(默认为空)
password:
# 连接超时时间
timeout: 10s
lucene:
index:
path: D:\lucene\index