添加SpringBoot Admin监控中心支持
This commit is contained in:
@@ -70,6 +70,8 @@ public class SecurityConfig extends WebSecurityConfigurerAdapter {
|
||||
.permitAll()
|
||||
.antMatchers(HttpMethod.OPTIONS)//跨域请求会先进行一次options请求
|
||||
.permitAll()
|
||||
.antMatchers("/actuator/**")// 允许SpringBoot Admin 访问监控信息
|
||||
.permitAll()
|
||||
// .antMatchers("/**")//测试时全部运行访问
|
||||
// .permitAll()
|
||||
.anyRequest()// 除上面外的所有请求全部需要鉴权认证
|
||||
|
||||
@@ -17,4 +17,12 @@ eureka:
|
||||
register-with-eureka: true
|
||||
fetch-registry: true
|
||||
service-url:
|
||||
defaultZone: http://localhost:8001/eureka/
|
||||
defaultZone: http://localhost:8001/eureka/
|
||||
management: #开启SpringBoot Admin的监控
|
||||
endpoints:
|
||||
web:
|
||||
exposure:
|
||||
include: '*'
|
||||
endpoint:
|
||||
health:
|
||||
show-details: always
|
||||
Reference in New Issue
Block a user