Files
UserhomeService/src/main/resources/application.yml
T
2026-08-21 14:25:08 +08:00

63 lines
2.2 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.
server:
port: 8070
servlet:
context-path: /
spring:
application:
name: userhome
# 关闭 Spring Cloud 对 nacos 配置中心的强制 spring.config.import 校验:
# 本项目用 spring-cloud-starter-bootstrap + bootstrap.yml 的老机制加载 nacos(enabled 控制开关),
# 不依赖 2.4+ 的 configdata import 机制——否则 classpath 含 nacos-config 会强制要求声明 spring.config.import,
# 且该 import 在本地 bootstrap.yml 尚未加载时因 server-addr 为空而硬连失败。
# 本地 enabled=false 纯走 application.yml;CI 注入 NACOS_CONFIG_ENABLED=true 走 bootstrap.yml 老路径拉配置。
cloud:
nacos:
config:
import-check:
enabled: false
datasource:
url: jdbc:mysql://localhost:3306/bsch_userhome?useUnicode=true&characterEncoding=utf8&useSSL=false&serverTimezone=Asia/Shanghai&allowPublicKeyRetrieval=true
username: root
password: 123456
driver-class-name: com.mysql.cj.jdbc.Driver
jpa:
hibernate:
ddl-auto: update
show-sql: false
open-in-view: false
properties:
hibernate:
jdbc:
time_zone: Asia/Shanghai
redis:
host: localhost
port: 6379
database: 0
# ===== 基础平台 yh 配置(遵循 yh-* spring-boot-starter 约定,具体 key 以对应 starter 版本为准)=====
yh:
auth:
# CAS 单点登录(浏览器 SSO 重定向 / ticket 校验)
cas:
server-url-prefix: https://sso.yunhaixingtong.com/cas
service: http://localhost:8070
app-auth:
# 应用间签名鉴权(UserHome 作为调用方访问 UserBase 跨仓接口时使用)
enabled: true
# UserHome 在 UserBase 注册得到的 appKey/appSecret(应用注册后填入)
app-key: 100001
app-secret: ec4e860206374c80938719fff8e14a86
open:
# yh-openapi 开放接口客户端(前缀必须是 yh.open,OpenApiProperties 绑定;base-host + base-path 拼出
# 完整跨仓基址,openapi 客户端再拼 /oapi/** 端点;app-key/app-secret 同时驱动应用间签名)
enabled: true
base-host: http://localhost:8060
base-path: /userbase
app-key: 100001
app-secret: ec4e860206374c80938719fff8e14a86
logging:
level:
com.yunhai.userhome: debug