cockpit-source/backend/configs/config.example.yaml
2026-04-02 14:12:43 +08:00

20 lines
453 B
YAML

server:
addr: ":8080"
db:
driver: "mysql"
# MySQL DSN: user:pass@tcp(host:port)/db?charset=utf8mb4&parseTime=True&loc=Local
dsn: "root:root@tcp(127.0.0.1:3306)/cockpit?charset=utf8mb4&parseTime=True&loc=Local"
auth:
# 请务必替换为强随机串
accessTokenSecret: "change-me-access"
refreshTokenSecret: "change-me-refresh"
accessTokenTtl: "15m"
refreshTokenTtl: "720h" # 30d
cors:
allowOrigins:
- "http://localhost:5173"