bootstrap.yml 4.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130
  1. server:
  2. port: 9095
  3. servlet:
  4. encoding:
  5. charset: UTF-8
  6. force: true
  7. enabled: true
  8. spring:
  9. profiles:
  10. active: dev
  11. application:
  12. name: aj-report
  13. servlet:
  14. multipart:
  15. max-file-size: 10MB #上传图片大小限制为10MB
  16. jackson:
  17. date-format: yyyy-MM-dd HH:mm:ss
  18. time-zone: GMT+8
  19. messages:
  20. basename: i18n/messages
  21. datasource:
  22. url: jdbc:mysql://10.108.26.197:3306/aj_report?characterEncoding=UTF-8&serverTimezone=Asia/Shanghai&useSSL=false
  23. username: root
  24. password: appuser@anji
  25. driver-class-name: com.mysql.cj.jdbc.Driver
  26. type: com.alibaba.druid.pool.DruidDataSource
  27. #数据源连接池配置
  28. druid:
  29. initial-size: 50
  30. min-idle: 50
  31. max-active: 100
  32. # 获取连接等待超时的时间
  33. max-wait: 5000
  34. # 配置间隔多久才进行一次检测
  35. time-between-eviction-runs-millis: 60000
  36. # 配置一个连接在池中最小生存时间
  37. min-evictable-idle-time-millis: 300000
  38. validation-query: select 1
  39. # 获取连接时执行检测,每次检测timeBetweenEvictionRunsMillis,空闲时间超过了minEvictableIdleTimeMillis则会直接剔除
  40. test-while-idle: true
  41. test-on-borrow: false
  42. test-on-return: false
  43. # 是否开启PSCache,PSCache对支持游标的数据库性能提升巨大,oracle建议开启,mysql下建议关闭
  44. pool-prepared-statements: false
  45. max-pool-prepared-statement-per-connection-size: 50
  46. filters: stat,wall
  47. connection-properties: druid.stat.mergeSql=true;druid.stat.slowSqlMillis=500
  48. use-global-data-source-stat: true
  49. #StatViewServlet配置
  50. stat-view-servlet.enabled: false
  51. #注意:账号密码需修改
  52. stat-view-servlet.login-username: admin
  53. stat-view-servlet.login-password: admin
  54. stat-view-servlet.allow: ""
  55. connectionErrorRetryAttempts: 3 # 连接出错后再尝试连接三次
  56. breakAfterAcquireFailure: true # 数据库服务宕机自动重连机制
  57. timeBetweenConnectErrorMillis: 300000 # 连接出错后重试时间间隔
  58. #如果要使用redis,请参考report-core目录下的README.md文件中写的进行调整
  59. # redis:
  60. # host: 127.0.0.1
  61. # port: 6379
  62. # password: root
  63. # database: 1
  64. flyway:
  65. enabled: false #是否开启flyway(自动执行sql脚本),默认false
  66. baseline-on-migrate: true
  67. #数据库连接配置
  68. url: ${spring.datasource.url}
  69. user: ${spring.datasource.username}
  70. password: ${spring.datasource.password}
  71. placeholder-replacement: false
  72. init-sqls:
  73. - CREATE DATABASE IF NOT EXISTS `aj_report` DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci;
  74. gaea:
  75. subscribes:
  76. oss: #文件存储 都配置的情况下优先级minio->amazonS3->nfs
  77. enabled: true
  78. ##允许上传的文件后缀
  79. file-type-while-list: .png|.jpg|.gif|.icon|.pdf|.xlsx|.xls|.csv|.mp4|.avi|.jpeg|.aaa|.svg
  80. # 用于文件上传成功后,生成文件的下载公网完整URL,http://serverip:9095/file/download,注意填写IP必须填写后端服务所在的机器IP
  81. downloadPath: http://10.108.26.197:9095/file/download
  82. nfs:
  83. #上传对应本地全路径,注意目录不会自动创建,注意 Win是 \ 且有盘符,linux是 / 无盘符,注意目录权限问题
  84. path: /app/disk/upload/
  85. #若要使用minio文件存储,请启用以下配置
  86. #minio:
  87. # url: http://127.0.0.1
  88. # port: 9000
  89. # access-key: minioreport
  90. # secret-key: minioreport
  91. # bucket-name: aj-report
  92. #若要使用amazonS3文件存储,请启用以下配置
  93. #amazonS3:
  94. # url: http://127.0.0.1
  95. # access-key: access-key
  96. # secret-key: secret-key
  97. # bucket-name: AJ-Report
  98. #若minio和amazonS3都没有,使用服务器高可用的nfs共享盘
  99. Security:
  100. # jwt密钥,生产环境请自行修改,避免被远程伪造登录攻击
  101. jwtSecret: TybmmfrgsIqpPsBOYxvygCMVJWKNfDJU
  102. mybatis-plus:
  103. configuration:
  104. log-impl: org.apache.ibatis.logging.stdout.StdOutImpl #开启sql打印
  105. call-setters-on-nulls: true
  106. mapperLocations:
  107. - classpath*:/mapper/**/*.xml
  108. - classpath*:/modeler-mybatis-mappings/**/*.xml
  109. management:
  110. endpoints:
  111. web:
  112. base-path: /
  113. logging:
  114. config: classpath:logback.xml
  115. # 本应用自定义参数
  116. customer:
  117. # 跳过token验证和权限验证的url清单
  118. skip-authenticate-urls: /gaeaDict/all, /login, /static, /file/download/, /index.html, /favicon.ico, /reportShare/detailByCode, /v2/api-docs, /reportExcel/exportExcel
  119. file:
  120. #导入导出临时文件夹 默认.代表当前目录,拼接/tmp_zip/目录
  121. tmpPath: .
  122. user:
  123. ##新增用户默认密码
  124. default:
  125. password: 123456