petstore-backend/src/main/resources/application-example.yml
2026-04-17 13:43:34 +08:00

47 lines
1.1 KiB
YAML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# 复制为 application.yml 后填写本地/生产配置application.yml 已加入 .gitignore勿提交密钥
spring:
application:
name: petstore-backend
datasource:
url: jdbc:mysql://127.0.0.1:3306/petstore?useUnicode=true&characterEncoding=utf8&serverTimezone=Asia/Shanghai&autoReconnect=true
username: root
password: ${MYSQL_PASSWORD:changeme}
driver-class-name: com.mysql.cj.jdbc.Driver
hikari:
max-lifetime: 1800000
connection-test-query: SELECT 1
validation-timeout: 3000
idle-timeout: 600000
jpa:
hibernate:
ddl-auto: update
show-sql: true
properties:
hibernate:
dialect: org.hibernate.dialect.MySQLDialect
format_sql: true
servlet:
multipart:
max-file-size: 200MB
max-request-size: 200MB
server:
port: 8080
servlet:
context-path:
tomcat:
max-http-form-post-size: 200MB
max-swallow-size: 200MB
upload:
path: uploads
logging:
level:
com.petstore: debug
wechat:
appid: ${WECHAT_APPID:}
appsecret: ${WECHAT_APPSECRET:}
redirect_uri: http://localhost:8080/api/wechat/callback