82 lines
2.1 KiB
YAML
82 lines
2.1 KiB
YAML
server:
|
||
port: 8080
|
||
servlet:
|
||
context-path: /api
|
||
|
||
spring:
|
||
application:
|
||
name: by-crm
|
||
datasource:
|
||
type: com.alibaba.druid.pool.DruidDataSource
|
||
driver-class-name: com.mysql.cj.jdbc.Driver
|
||
url: jdbc:mysql://192.168.3.80:3306/by_crm?useUnicode=true&characterEncoding=utf8&serverTimezone=Asia/Shanghai&useSSL=false&allowPublicKeyRetrieval=true
|
||
username: root
|
||
password: "Boyun@123"
|
||
druid:
|
||
initial-size: 5
|
||
min-idle: 5
|
||
max-active: 20
|
||
max-wait: 60000
|
||
time-between-eviction-runs-millis: 60000
|
||
min-evictable-idle-time-millis: 300000
|
||
validation-query: SELECT 1
|
||
test-while-idle: true
|
||
test-on-borrow: false
|
||
test-on-return: false
|
||
filters: stat,wall
|
||
web-stat-filter:
|
||
enabled: true
|
||
url-pattern: /*
|
||
stat-view-servlet:
|
||
enabled: true
|
||
url-pattern: /druid/*
|
||
reset-enable: false
|
||
login-username: admin
|
||
login-password: admin123
|
||
|
||
jackson:
|
||
time-zone: GMT+8
|
||
date-format: yyyy-MM-dd HH:mm:ss
|
||
default-property-inclusion: non_null
|
||
|
||
mvc:
|
||
pathmatch:
|
||
matching-strategy: ant_path_matcher
|
||
|
||
# MyBatis 配置
|
||
mybatis:
|
||
mapper-locations: classpath:mapper/*.xml
|
||
type-aliases-package: com.bycrm.entity
|
||
configuration:
|
||
map-underscore-to-camel-case: true
|
||
cache-enabled: false
|
||
log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
|
||
|
||
# JWT 配置
|
||
jwt:
|
||
# HS512 算法要求密钥至少 64 字节(512 位)
|
||
# 生产环境请使用环境变量或密钥管理系统存储此密钥
|
||
secret: by-crm-jwt-secret-key-2024-hs512-requires-at-least-64-bytes-for-secure-signing-please-change-in-production-environment
|
||
expiration: 86400000 # 24小时,单位:毫秒
|
||
|
||
# CRM 业务配置
|
||
crm:
|
||
report:
|
||
ttl-days: 90 # 保护期天数
|
||
allow-overlap: false # 是否允许重叠报备(生产环境必须为 false)
|
||
|
||
# Swagger 配置
|
||
springfox:
|
||
documentation:
|
||
swagger-ui:
|
||
enabled: true
|
||
enabled: true
|
||
|
||
# 日志配置
|
||
logging:
|
||
level:
|
||
com.bycrm.mapper: debug
|
||
org.springframework.web: info
|
||
pattern:
|
||
console: '%d{yyyy-MM-dd HH:mm:ss} [%thread] %-5level %logger{50} - %msg%n'
|