Skip to content

Commit

Permalink
chore: 임시 url cors허용
Browse files Browse the repository at this point in the history
  • Loading branch information
jeong011010 committed Oct 27, 2024
1 parent 1612d78 commit 6c1b744
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion nginx/conf.d/nginx.conf
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ server {
proxy_pass_header Authorization;

# CORS headers for all requests
if ($http_origin ~* (http://localhost:3000|https://chekirout-fe.vercel.app)) {
if ($http_origin ~* (http://localhost:3000|https://chekirout-fe.vercel.app|https::/chekirout.pages.dev)) {
add_header 'Access-Control-Allow-Origin' "$http_origin" always;
add_header 'Access-Control-Allow-Credentials' 'true' always;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ public class WebConfig implements WebMvcConfigurer {
public void addCorsMappings(CorsRegistry registry) {

registry.addMapping("/**")
.allowedOrigins("http://localhost:3000", "https://chekirout-fe.vercel.app")
.allowedOrigins("http://localhost:3000", "https://chekirout-fe.vercel.app", "https://chekirout.pages.dev")
.allowedMethods("GET", "POST", "PUT", "DELETE", "PATCH", "OPTIONS")
.allowedHeaders("Authorization", "Content-Type")
.exposedHeaders("Authorization", "Custom-Header")
Expand Down

0 comments on commit 6c1b744

Please sign in to comment.