application.yml 4.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145
  1. server:
  2. port: 8001
  3. servlet:
  4. context-path: /api/v1
  5. spring:
  6. threads:
  7. virtual:
  8. enabled: true
  9. application:
  10. name: payment-platform
  11. profiles:
  12. active: dev
  13. servlet:
  14. multipart:
  15. max-file-size: 10MB
  16. max-request-size: 20MB
  17. jackson:
  18. time-zone: Asia/Shanghai
  19. datasource:
  20. type: com.alibaba.druid.pool.DruidDataSource
  21. druid:
  22. driver-class-name: org.postgresql.Driver
  23. url: jdbc:postgresql://localhost:5432/payment_platform_java?currentSchema=public&stringtype=unspecified
  24. username: admin
  25. password: 'xjz#123321'
  26. initial-size: 5
  27. min-idle: 5
  28. max-active: 20
  29. max-wait: 60000
  30. validation-query: SELECT 1
  31. test-while-idle: true
  32. test-on-borrow: false
  33. test-on-return: false
  34. # 每个物理连接建立后立刻把会话时区钉成北京时间。
  35. #
  36. # 为什么必须有这一行:本项目所有 timestamp without time zone 列一律存北京墙钟
  37. # (由 ShanghaiOffsetDateTimeTypeHandler 保证),那部分与会话时区无关;
  38. # 但业务表里另有 4 个 timestamptz 列存的是「瞬间」,读出来是会话时区的墙钟 ——
  39. # sys_invitation_code.used_time / created_time / updated_time、sys_user.last_login
  40. # 这几列的正确性完全押在会话时区上,所以在这里显式钉死,不依赖服务端配置。
  41. #
  42. # 已核对 druid-spring-boot-3-starter 1.2.20 的 spring-configuration-metadata.json:
  43. # 属性名就是 connection-init-sqls(Collection<String>);
  44. # 并已反编译 DruidAbstractDataSource 确认它在建连后逐条
  45. # connection.createStatement() + Statement.execute(sql)。
  46. connection-init-sqls:
  47. - SET TIME ZONE 'Asia/Shanghai'
  48. data:
  49. redis:
  50. host: redis
  51. port: 6379
  52. database: 1
  53. password: '123456#xjz'
  54. timeout: 10s
  55. lettuce:
  56. pool:
  57. max-active: 20
  58. max-idle: 10
  59. min-idle: 5
  60. mybatis-plus:
  61. mapper-locations: classpath*:/mapper/**/*.xml
  62. type-aliases-package: com.payment.platform.module
  63. configuration:
  64. map-underscore-to-camel-case: true
  65. log-impl: org.apache.ibatis.logging.slf4j.Slf4jImpl
  66. # JWT
  67. jwt:
  68. secret: vgb0tnl9d58+6n-6h-ea&u^1#1sccp!794=krylxcjq75vzps$
  69. algorithm: HmacSHA256
  70. access-token-expire: 3600
  71. refresh-token-expire: 7200
  72. token-type: bearer
  73. sliding-expire: true
  74. # 验证码
  75. captcha:
  76. enable: true
  77. expire-seconds: 60
  78. # Knife4j
  79. springdoc:
  80. swagger-ui:
  81. path: /swagger-ui.html
  82. api-docs:
  83. path: /v3/api-docs
  84. knife4j:
  85. enable: true
  86. setting:
  87. language: zh_cn
  88. # Alipay(仅作 fallback — 正常运行时使用 pay_service_provider 表配置)
  89. alipay:
  90. app-id: ""
  91. app-private-key: ""
  92. alipay-public-key: ""
  93. server-url: https://openapi.alipay.com/gateway.do
  94. format: JSON
  95. charset: UTF-8
  96. sign-type: RSA2
  97. sandbox: false
  98. notify-url: ""
  99. return-url: ""
  100. # OAuth 授权回调完成后的前端跳转地址(如 http://localhost:5180)— openid 授权 URL 生成时校验非空
  101. oauth-front-url: "https://qcsj88888.com"
  102. # OAuth 授权回调地址(完整 URL)— 支付宝开放平台「授权回调地址」白名单只能配一个,与当面付 app_auth_code 授权共用(按参数分流),须与白名单完全一致
  103. oauth-redirect-uri: "https://qcsj88888.com/api/v1/payment/aplipay/auth"
  104. max-retries: 3
  105. request-timeout: 30
  106. rate-limit: 100
  107. # Alibaba Cloud (OSS等)
  108. alibaba-cloud:
  109. access-key-id: LTAI5t5jHkQMY2T7V5n4ofMr
  110. access-key-secret: RYaofbQBRc93LC1oxCbgJGTVMCzNW4
  111. # File upload (OSS)
  112. file:
  113. upload-path: static/upload
  114. allowed-extensions: .gif,.jpg,.jpeg,.png,.ico,.svg,.xls,.xlsx,.pdf,.doc,.docx
  115. max-size: 10485760
  116. # Aliyun OSS
  117. aliyun:
  118. oss:
  119. endpoint: "oss-cn-beijing.aliyuncs.com"
  120. bucket: "hunanxiaojunzioss"
  121. access-key-id: "LTAI5t5jHkQMY2T7V5n4ofMr"
  122. access-key-secret: "RYaofbQBRc93LC1oxCbgJGTVMCzNW4"
  123. custom-domain: ""
  124. # Logging
  125. logging:
  126. file:
  127. path: ./logs
  128. level:
  129. com.payment.platform: info
  130. org.springframework.security: info