Files
orion-visor/orion-visor-launch/src/main/resources/application.yaml

302 lines
7.6 KiB
YAML
Raw Normal View History

2023-06-20 16:05:15 +08:00
server:
2024-05-29 11:57:14 +08:00
port: 9200
2023-06-20 16:05:15 +08:00
spring:
application:
2024-06-17 10:13:23 +08:00
name: orion-visor
2023-06-20 16:05:15 +08:00
profiles:
active: dev
main:
# 允许循环依赖
allow-circular-references: true
servlet:
# 文件上传相关配置项
multipart:
# 单个文件大小
max-file-size: 16MB
2024-02-27 15:20:40 +08:00
# 消息体大小
2023-06-20 16:05:15 +08:00
max-request-size: 32MB
mvc:
pathmatch:
matching-strategy: ANT_PATH_MATCHER
2024-06-04 18:34:19 +08:00
async:
# 异步请求时间 30min
request-timeout: 1800000
datasource:
druid:
driver-class-name: com.mysql.cj.jdbc.Driver
# 初始连接数
initial-size: 5
# 最小连接池数量
min-idle: 5
# 最大连接池数量
max-active: 20
# 配置获取连接等待超时的时间
max-wait: 600000
# 检测间隔
time-between-eviction-runs-millis: 60000
# 最小生存的时间
min-evictable-idle-time-millis: 300000
# 最大生存的时间
max-evictable-idle-time-millis: 900000
validation-query: SELECT 1
2024-06-11 11:12:44 +08:00
# 控制台
stat-view-servlet:
enabled: true
url-pattern: /druid/*
login-username:
login-password:
2024-06-11 11:12:44 +08:00
web-stat-filter:
enabled: true
filter:
stat:
enabled: true
log-slow-sql: true
slow-sql-millis: 800
merge-sql: true
wall:
config:
multi-statement-allow: true
2024-03-26 23:56:26 +08:00
redis:
database: 0
2024-03-28 12:05:30 +08:00
connect-timeout: 5000
2024-03-26 23:56:26 +08:00
timeout: 3000
cache:
type: REDIS
redis:
time-to-live: 1h
2023-06-28 22:04:47 +08:00
output:
ansi:
enabled: DETECT
2024-03-27 01:07:47 +08:00
quartz:
job-store-type: JDBC
overwrite-existing-jobs: false
jdbc:
2024-04-03 11:00:18 +08:00
initialize-schema: NEVER
2024-03-27 01:07:47 +08:00
properties:
org:
quartz:
scheduler:
# 实例 ID
instanceId: AUTO
instanceName: quartzScheduler
jobStore:
# 持久化配置
2024-08-25 00:50:16 +08:00
class: org.springframework.scheduling.quartz.LocalDataSourceJobStore
2024-03-27 01:07:47 +08:00
driverDelegateClass: org.quartz.impl.jdbcjobstore.StdJDBCDelegate
useProperties: false
tablePrefix: QRTZ_
misfireThreshold: 60000
clusterCheckinInterval: 5000
2024-08-25 00:50:16 +08:00
isClustered: false
2024-06-11 11:12:44 +08:00
# 连接池
2024-03-27 01:07:47 +08:00
threadPool:
class: org.quartz.simpl.SimpleThreadPool
2024-03-29 11:12:34 +08:00
threadCount: 5
2024-03-27 01:07:47 +08:00
threadPriority: 5
threadsInheritContextClassLoaderOfInitializingThread: true
boot:
admin:
context-path: /admin
client:
2024-06-11 11:12:44 +08:00
enabled: true
url: http://127.0.0.1:${server.port}/${spring.boot.admin.context-path}
instance:
service-host-type: IP
2024-06-11 11:12:44 +08:00
server:
enabled: true
management:
endpoints:
2024-06-11 11:12:44 +08:00
enabled-by-default: true
web:
base-path: /actuator
exposure:
include: '*'
2023-06-20 16:05:15 +08:00
mybatis-plus:
configuration:
map-underscore-to-camel-case: true
mapper-locations: classpath*:mapper/*Mapper.xml
global-config:
db-config:
logic-delete-field: deleted
2023-07-06 15:01:36 +08:00
logic-not-delete-value: 0
logic-delete-value: 1
2023-06-21 18:34:22 +08:00
springdoc:
api-docs:
enabled: true
path: /v3/api-docs
swagger-ui:
enabled: true
path: /swagger-ui
tags-sorter: alpha
operations-sorter: alpha
show-extensions: true
knife4j:
enable: true
setting:
language: ZH_CN
2023-06-21 18:34:22 +08:00
2023-06-28 22:04:47 +08:00
logging:
file:
2024-06-17 10:13:23 +08:00
path: ${user.home}/orion/logs/${spring.application.name}
2023-06-28 22:04:47 +08:00
name: ${logging.file.path}/app.log
logback:
rollingpolicy:
clean-history-on-start: false
2024-03-27 01:07:47 +08:00
file-name-pattern: ${logging.file.path}/rolling/rolling-%d{yyyy-MM-dd}.%i.gz
2023-06-28 22:04:47 +08:00
max-history: 30
max-file-size: 16MB
total-size-cap: 0B
pattern:
2023-10-31 01:32:13 +08:00
console: '%clr(%d{${LOG_DATEFORMAT_PATTERN:yyyy-MM-dd HH:mm:ss.SSS}}){faint} %clr(${LOG_LEVEL_PATTERN:-%6p}) %boldBlue([%X{tid}]) %clr([%22.22t]){faint} %clr(%-40.40logger{39}){cyan} %clr(:){faint} %m%n${LOG_EXCEPTION_CONVERSION_WORD:%wEx}'
file: "%d{${LOG_DATEFORMAT_PATTERN:yyyy-MM-dd HH:mm:ss.SSS}} ${LOG_LEVEL_PATTERN:-%6p} [%X{tid}] [%t] %-40.40logger{39} : %m%n${LOG_EXCEPTION_CONVERSION_WORD:%wEx}"
level:
2024-05-16 00:03:30 +08:00
com.orion.visor.launch.controller.BootstrapController: INFO
2023-06-28 22:04:47 +08:00
2024-03-05 19:31:00 +08:00
# 应用配置
app:
# 认证配置
2024-03-05 19:31:00 +08:00
authentication:
# 是否允许多端登录
allow-multi-device: true
# 是否允许凭证续签
allow-refresh: true
# 凭证续签最大次数
max-refresh-count: 3
2024-08-20 10:20:35 +08:00
# 登录失败发送站内信阈值
login-failed-send-threshold: 3
2024-03-05 19:31:00 +08:00
# 登录失败锁定次数
login-failed-lock-count: 5
# 登录失败锁定时间 (分)
login-failed-lock-time: 30
# tracker 配置
tracker:
# 加载偏移量 (行)
offset: 300
# 延迟时间 (ms)
delay: 100
# 文件未找到等待次数
wait-times: 100
# sftp 配置
sftp:
# 上传文件时 文件存在是否备份
upload-present-backup: true
# 备份文件名称
backup-file-name: bk_${fileName}_${timestamp}
# 执行日志
exec-log:
2024-04-25 19:00:12 +08:00
# 是否拼接 ansi 执行状态日志
append-ansi: true
2024-06-25 10:42:32 +08:00
# 自动清理配置
auto-clear:
# 批量执行日志
exec-log:
enabled: false
keep-period: 30
2024-10-15 12:36:11 +08:00
# 终端连接日志
terminal-connect-log:
2024-06-25 10:42:32 +08:00
enabled: false
keep-period: 30
2024-03-05 19:31:00 +08:00
# orion framework config
2023-06-20 16:05:15 +08:00
orion:
# 版本
version: @revision@
2024-05-23 13:56:03 +08:00
# 是否为演示模式
demo: false
2023-06-20 16:05:15 +08:00
api:
2023-12-28 11:44:04 +08:00
# 公共 api 前缀
2024-05-16 13:53:03 +08:00
prefix: /orion-visor/api
2024-05-31 13:36:49 +08:00
# 是否允许跨域
2023-06-20 16:05:15 +08:00
cors: true
2023-12-28 11:44:04 +08:00
websocket:
# 公共 websocket 前缀
2024-05-16 13:53:03 +08:00
prefix: /orion-visor/keep-alive
2023-12-28 11:44:04 +08:00
# 1MB
binary-buffer-size: 1048576
# 1MB
text-buffer-size: 1048576
# 30MIN
session-idle-timeout: 1800000
2023-06-21 18:34:22 +08:00
swagger:
# swagger 配置
author: Jiahang Li
2024-05-16 00:03:30 +08:00
title: orion-visor 运维平台
2023-07-08 02:11:30 +08:00
description: 一站式运维服务平台
2023-06-21 18:34:22 +08:00
version: ${orion.version}
2024-06-12 15:13:07 +08:00
url: https://github.com/dromara/orion-visor
2023-06-21 18:34:22 +08:00
email: ljh1553488six@139.com
license: Apache-2.0
2024-06-12 15:13:07 +08:00
license-url: https://github.com/dromara/orion-visor/blob/main/LICENSE
grouped-api:
infra:
group: "infra - 基建模块"
path: "infra"
2023-10-09 16:25:19 +08:00
asset:
group: "asset - 资产模块"
path: "asset"
logging:
# 全局日志打印
printer:
mode: PRETTY
2024-05-16 00:03:30 +08:00
expression: 'execution (* com.orion.visor..*.controller..*.*(..))'
headers:
- user-agent,accept
- content-type
2023-10-12 12:59:56 +08:00
# 下面引用了 需要注意
field:
ignore:
2023-11-01 18:57:53 +08:00
- password,beforePassword,newPassword,useNewPassword,publicKey,privateKey,token
- metrics
desensitize:
storage:
# 本地文件存储
local:
2023-07-14 11:17:55 +08:00
primary: true
2023-07-08 02:11:30 +08:00
enabled: true
2024-03-11 18:46:23 +08:00
timestamp-prefix: false
2024-03-12 10:58:20 +08:00
date-directory: false
2023-07-08 02:11:30 +08:00
storage-path: ${user.home}
2024-06-17 10:13:23 +08:00
base-path: /orion/${spring.application.name}/storage
2024-03-12 10:58:20 +08:00
# 日志文件存储
logs:
enabled: true
timestamp-prefix: false
date-directory: false
storage-path: ${user.home}
2024-06-17 10:13:23 +08:00
base-path: /orion/${spring.application.name}/logs
security:
password-encoder-length: 4
# 匿名接口
permit-url:
2023-07-08 02:11:30 +08:00
- ${orion.api.prefix}/server/bootstrap/health
crypto:
# aes加密器
aes:
2023-07-14 18:11:37 +08:00
primary: true
2023-07-08 02:11:30 +08:00
enabled: true
working-mode: ECB
padding-mode: PKCS5_PADDING
2024-05-17 12:26:01 +08:00
# 加密密钥
2023-07-08 02:11:30 +08:00
secret-key: I66AndrKWrwXjtBL
use-generator-key: true
generator-key-length: 128
2023-10-09 16:25:19 +08:00
async:
# 线程池配置
2023-10-09 16:25:19 +08:00
executor:
core-pool-size: 2
max-pool-size: 4
queue-capacity: 30
2023-10-09 16:25:19 +08:00
keep-alive-seconds: 180
2023-10-10 16:56:56 +08:00
operator-log:
2023-10-10 18:37:17 +08:00
error-message-length: 255
2023-10-12 12:59:56 +08:00
user-agent-length: 128
ignore:
- ${orion.logging.printer.field.ignore[0]}
- ${orion.logging.printer.field.ignore[1]}
desensitize: