增加探针配置
All checks were successful
Build Push and Deploy Image / build (push) Successful in 22m32s

This commit is contained in:
bamanker
2026-01-08 13:59:30 +08:00
parent 54202d8fd7
commit 06cfebccab
3 changed files with 77 additions and 20 deletions

View File

@@ -56,4 +56,25 @@ logging:
level:
com.bamanker.dailylove.service: debug #指定openfeign日志以什么级别监控哪个接口可多个
scanclass: false
scanclass: false
# Actuator 配置
management:
# 端点配置
endpoints:
web:
exposure:
# 暴露健康端点,生产环境要慎重,别把敏感信息暴露了
include: health,info
# 健康端点配置
endpoint:
health:
# 显示详细的健康信息,方便调试
# 生产环境建议设为 when-authorized需要认证才能看详情
show-details: always
# 开启探针支持,这个必须设置
probes:
enabled: true
# 在主端口上也暴露探针路径
# 这样 K8s 探针可以直接访问应用端口,不用单独配置 management 端口
add-additional-paths: true