From 454b37ce7b7de6d0e25ac7cc0c696d5c1fe74b84 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matheus=20Lu=C3=ADs?= Date: Tue, 21 May 2024 08:02:51 -0300 Subject: [PATCH] remove cors from nginx conf --- nginx.conf | 15 --------------- 1 file changed, 15 deletions(-) diff --git a/nginx.conf b/nginx.conf index 70a430b..8438144 100644 --- a/nginx.conf +++ b/nginx.conf @@ -41,21 +41,6 @@ http { proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header X-Forwarded-Proto $scheme; - - add_header 'Access-Control-Allow-Origin' '*'; - add_header 'Access-Control-Allow-Methods' 'GET, POST, OPTIONS'; - add_header 'Access-Control-Allow-Headers' 'Content-Type, Origin, Accept, Authorization, X-Request-With, X-API-KEY'; - add_header 'Access-Control-Allow-Credentials' 'true'; - - if ($request_method = 'OPTIONS') { - add_header 'Access-Control-Allow-Origin' '*'; - add_header 'Access-Control-Allow-Methods' 'GET, POST, OPTIONS'; - add_header 'Access-Control-Allow-Headers' 'Content-Type, Origin, Accept, Authorization, X-Request-With, X-API-KEY'; - add_header 'Access-Control-Allow-Credentials' 'true'; - add_header 'Content-Length' 0; - add_header 'Content-Type' 'text/plain; charset=utf-8'; - return 204; - } } } } \ No newline at end of file