Skip to content

Commit 3437d3b

Browse files
committed
chore : actuator 권한 추가 (#6)
1 parent 396a206 commit 3437d3b

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

src/main/java/cmf/commitField/global/security/SecurityConfig.java

+7
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,13 @@ public SecurityConfig(CustomOAuth2UserService customOAuth2UserService) {
2323

2424
@Bean
2525
protected SecurityFilterChain config(HttpSecurity http) throws Exception {
26+
// 권한 설정
27+
http
28+
.authorizeHttpRequests(auth -> auth
29+
.requestMatchers("/actuator/**").permitAll() // actuator 엔드포인트 허용
30+
.anyRequest().authenticated() // 그 외 모든 요청은 인증 필요
31+
);
32+
2633
//로그인 관련 설정
2734
http
2835
.oauth2Login(oauth2 -> oauth2

0 commit comments

Comments
 (0)