Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: 새 배포주소 CORS 설정 추가 #158

Merged
merged 1 commit into from
Feb 21, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/main/java/muit/backend/config/WebConfig.java
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ public class WebConfig implements WebMvcConfigurer {
@Override
public void addCorsMappings(CorsRegistry registry) {
registry.addMapping("/**")
.allowedOrigins("http://localhost:5173", "http://localhost:8080", "http://13.209.69.125:8080", "https://muitproject.vercel.app", "http://muit-front.s3-website.ap-northeast-2.amazonaws.com", "http://muit.site", "https://muit.site")
.allowedOrigins("http://localhost:5173", "http://localhost:8080", "http://13.209.69.125:8080", "https://muitproject.vercel.app", "http://muit-front.s3-website.ap-northeast-2.amazonaws.com", "http://muit.site", "https://muit.site", "https://musical-dodol-afad4e.netlify.app")
.allowedMethods("GET", "POST", "PUT", "DELETE", "OPTIONS", "HEAD", "PATCH")
.allowedHeaders("*")
.allowCredentials(true)
Expand Down
1 change: 1 addition & 0 deletions src/main/java/muit/backend/config/jwt/SecurityConfig.java
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ public SecurityFilterChain securityFilterChain(HttpSecurity http) throws Excepti
config.addAllowedOrigin("http://muit-front.s3-website.ap-northeast-2.amazonaws.com"); //배포된 프론트엔드 주소 추가
config.addAllowedOrigin("http://muit.site"); //배포된 프론트엔드 주소 추가
config.addAllowedOrigin("https://muit.site"); //배포된 프론트엔드 주소 추가
config.addAllowedOrigin("https://musical-dodol-afad4e.netlify.app"); //배포된 프론트엔드 주소 추가
//config.addAllowedOrigin("*");
config.addAllowedHeader("*");
config.addAllowedMethod("*");
Expand Down