application.yaml 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293
  1. spring:
  2. application:
  3. name: dashboard
  4. # 数据源配置项 TODO 多数据源;TODO 监控配置
  5. datasource:
  6. url: jdbc:mysql://127.0.1:33061/ruoyi-vue-pro?useSSL=false&useUnicode=true&characterEncoding=UTF-8&serverTimezone=CTT
  7. driver-class-name: com.mysql.jdbc.Driver
  8. username: root
  9. password: 123456
  10. # Redis 配置。Redisson 默认的配置足够使用,一般不需要进行调优
  11. redis:
  12. host: 127.0.0.1 # 地址
  13. port: 6379 # 端口
  14. database: 0 # 数据库索引
  15. # Servlet 配置
  16. servlet:
  17. # 文件上传相关配置项
  18. multipart:
  19. max-file-size: 16MB # 单个文件大小
  20. max-request-size: 32MB # 设置总上传的文件大小
  21. # Spring Boot Admin 配置项
  22. boot:
  23. admin:
  24. # Spring Boot Admin Client 客户端的相关配置
  25. client:
  26. url: http://127.0.0.1:8080/${spring.boot.admin.context-path} # 设置 Spring Boot Admin Server 地址
  27. # Spring Boot Admin Server 服务端的相关配置
  28. context-path: /admin # 配置 Spring
  29. # Jackson 配置项
  30. jackson:
  31. serialization:
  32. write-dates-as-timestamps: true # 设置时间的格式,使用时间戳
  33. write-date-timestamps-as-nanoseconds: false # 设置不使用 nanoseconds 的格式。例如说 1611460870.401,而是直接 1611460870401
  34. # 芋道配置项,设置当前项目所有自定义的配置
  35. yudao:
  36. web:
  37. api-prefix: /api
  38. controller-package: cn.iocoder.dashboard
  39. security:
  40. token-header: Authorization
  41. token-secret: abcdefghijklmnopqrstuvwxyz
  42. token-timeout: 1d
  43. session-timeout: 30m
  44. mock-enable: true
  45. mock-secret: test
  46. swagger:
  47. title: 管理后台
  48. description: 提供管理员管理的所有功能
  49. version: 1.0.0
  50. base-package: cn.iocoder.dashboard.modules
  51. captcha:
  52. timeout: 5m
  53. width: 160
  54. height: 60
  55. file:
  56. base-path: http://127.0.0.1:1024/api/file/get/
  57. # Apollo 配置中心
  58. apollo:
  59. bootstrap:
  60. enabled: true # 设置 Apollo 在启动阶段生效
  61. eagerLoad:
  62. enabled: true # 设置 Apollo 在日志初始化前生效,可以实现日志的动态级别配置
  63. jdbc: # 自定义的 JDBC 配置项,用于数据库的地址
  64. url: ${spring.datasource.url}
  65. username: ${spring.datasource.username}
  66. password: ${spring.datasource.password}
  67. # MyBatis Plus 的配置项
  68. mybatis-plus:
  69. configuration:
  70. map-underscore-to-camel-case: true # 虽然默认为 true ,但是还是显示去指定下。
  71. log-impl: org.apache.ibatis.logging.stdout.StdOutImpl # 打印日志
  72. global-config:
  73. db-config:
  74. id-type: auto # 自增 ID
  75. logic-delete-value: 1 # 逻辑已删除值(默认为 1)
  76. logic-not-delete-value: 0 # 逻辑未删除值(默认为 0)
  77. mapper-locations: classpath*:mapper/*.xml
  78. type-aliases-package: cn.iocoder.dashboard.modules.*.dal.mysql.dataobject
  79. # Actuator 监控端点的配置项
  80. management:
  81. endpoints:
  82. web:
  83. exposure:
  84. include: '*' # 需要开放的端点。默认值只打开 health 和 info 两个端点。通过设置 * ,可以开放所有端点。