【问题标题】:Spring boot admin not showing secured endpoints of spring boot clientSpring Boot 管理员未显示 Spring Boot 客户端的安全端点
【发布时间】:2020-11-13 12:19:45
【问题描述】:

安装了 spring boot admin 和 server。 所有客户端端点在 spring boot admin 中都是可见的,但是在客户端安全端点中添加安全依赖项后在 admin 中不可见。 在客户端的 application.yaml 中提供了管理员和客户端的凭据。

【问题讨论】:

    标签: spring-boot spring-boot-actuator spring-boot-admin


    【解决方案1】:

    遇到了同样的问题。首先,您需要从 admin-client 共享用户名和密码,这可以在 yml 文件中配置:

    spring.boot.admin.client:
        url: http://localhost:8080
        instance:
          metadata:
            user.name: ${spring.security.user.name}
            user.password: ${spring.security.user.password}
    

    您还需要在安全配置中启用 http basic,因为 SBA 服务器然后使用此元数据进行 http 调用。

    来源:https://codecentric.github.io/spring-boot-admin/2.2.3/#_securing_client_actuator_endpoints

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2016-06-27
      • 2015-08-26
      • 2022-11-28
      相关资源
      最近更新 更多