feat: swagger
This commit is contained in:
parent
fd5638aec2
commit
6d03363a0e
@ -18,6 +18,7 @@ public class WebConfiguration implements WebMvcConfigurer {
|
||||
|
||||
public WebConfiguration(JWTInterceptor jwtInterceptor) {
|
||||
super();
|
||||
|
||||
this.jwtInterceptor = jwtInterceptor;
|
||||
}
|
||||
|
||||
@ -42,7 +43,10 @@ public class WebConfiguration implements WebMvcConfigurer {
|
||||
@Override
|
||||
public void addInterceptors(InterceptorRegistry registry) {
|
||||
registry.addInterceptor(jwtInterceptor)
|
||||
|
||||
.addPathPatterns("/**") // 모든 경로에 대해 인터셉터 적용
|
||||
.excludePathPatterns("swagger-ui/**","/auth/**", "/board/**", "/user/**","/lecture/**","/qna/**"); // 인증 없이 접근 가능한 경로 설정
|
||||
.excludePathPatterns("/v3/api-docs/**","/swagger-resources/**","/webjars/**","/swagger-ui/**","/auth/**", "/board/**", "/user/**","/lecture/**","/qna/**"); // 인증 없이 접근 가능한 경로 설정
|
||||
|
||||
///v3/api-docs/**, /swagger-resources/**, /webjars/**
|
||||
}
|
||||
}
|
@ -28,8 +28,7 @@ spring.jpa.hibernate.ddl-auto=create
|
||||
spring.jpa.show-sql=true
|
||||
|
||||
|
||||
springdoc.api-docs.path=/api/v3/api-docs
|
||||
springdoc.swagger-ui.path=/api/swagger-ui.html
|
||||
|
||||
|
||||
spring.mail.host=smtp.gmail.com
|
||||
spring.mail.port=587
|
||||
|
Loading…
Reference in New Issue
Block a user