diff --git a/default.conf b/default.conf index 2a17472..0ca2572 100644 --- a/default.conf +++ b/default.conf @@ -13,13 +13,17 @@ server { location /admin-auth-service/ { + if ($request_method = OPTIONS) { add_header Access-Control-Allow-Origin $http_origin always; add_header Access-Control-Allow-Credentials true always; add_header Access-Control-Allow-Headers content-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; - if ($request_method = OPTIONS) { return 200; } + add_header Access-Control-Allow-Origin $http_origin always; + add_header Access-Control-Allow-Credentials true always; + add_header Access-Control-Allow-Headers content-type always; + add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_set_header Referer $host; proxy_set_header Origin $http_origin; proxy_set_header X-Real-IP $remote_addr; @@ -37,13 +41,17 @@ server { location /auth// { + if ($request_method = OPTIONS) { add_header Access-Control-Allow-Origin $http_origin always; add_header Access-Control-Allow-Credentials true always; add_header Access-Control-Allow-Headers content-type,authorization,response-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; - if ($request_method = OPTIONS) { return 200; } + add_header Access-Control-Allow-Origin $http_origin always; + add_header Access-Control-Allow-Credentials true always; + add_header Access-Control-Allow-Headers content-type,authorization,response-type always; + add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_set_header Referer $host; proxy_set_header Origin $http_origin; proxy_set_header X-Real-IP $remote_addr; @@ -54,13 +62,17 @@ server { } location /user/ { + if ($request_method = OPTIONS) { add_header Access-Control-Allow-Origin $http_origin always; add_header Access-Control-Allow-Credentials true always; add_header Access-Control-Allow-Headers content-type,authorization,response-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; - if ($request_method = OPTIONS) { return 200; } + add_header Access-Control-Allow-Origin $http_origin always; + add_header Access-Control-Allow-Credentials true always; + add_header Access-Control-Allow-Headers content-type,authorization,response-type always; + add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_set_header Referer $host; proxy_set_header Origin $http_origin; proxy_set_header X-Real-IP $remote_addr; @@ -76,13 +88,17 @@ server { location /heruvym/v1.0.0/ { + if ($request_method = OPTIONS) { add_header Access-Control-Allow-Origin $http_origin always; add_header Access-Control-Allow-Credentials true always; add_header Access-Control-Allow-Headers content-type,authorization,response-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; - if ($request_method = OPTIONS) { return 200; } + add_header Access-Control-Allow-Origin $http_origin always; + add_header Access-Control-Allow-Credentials true always; + add_header Access-Control-Allow-Headers content-type,authorization,response-type always; + add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_set_header Referer $host; proxy_set_header Origin $http_origin; proxy_set_header X-Real-IP $remote_addr; @@ -105,13 +121,17 @@ server { location /strator// { + if ($request_method = OPTIONS) { add_header Access-Control-Allow-Origin $http_origin always; add_header Access-Control-Allow-Credentials true always; add_header Access-Control-Allow-Headers content-type,authorization,response-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; - if ($request_method = OPTIONS) { return 200; } + add_header Access-Control-Allow-Origin $http_origin always; + add_header Access-Control-Allow-Credentials true always; + add_header Access-Control-Allow-Headers content-type,authorization,response-type always; + add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_set_header Referer $host; proxy_set_header Origin $http_origin; proxy_set_header X-Real-IP $remote_addr; @@ -129,13 +149,17 @@ server { location /customer/v1.0.1/ { + if ($request_method = OPTIONS) { add_header Access-Control-Allow-Origin $http_origin always; add_header Access-Control-Allow-Credentials true always; add_header Access-Control-Allow-Headers content-type,authorization,response-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; - if ($request_method = OPTIONS) { return 200; } + add_header Access-Control-Allow-Origin $http_origin always; + add_header Access-Control-Allow-Credentials true always; + add_header Access-Control-Allow-Headers content-type,authorization,response-type always; + add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_set_header Referer $host; proxy_set_header Origin $http_origin; proxy_set_header X-Real-IP $remote_addr; @@ -153,13 +177,17 @@ server { location /codeword/v1.0.0/ { + if ($request_method = OPTIONS) { add_header Access-Control-Allow-Origin $http_origin always; add_header Access-Control-Allow-Credentials true always; add_header Access-Control-Allow-Headers content-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; - if ($request_method = OPTIONS) { return 200; } + add_header Access-Control-Allow-Origin $http_origin always; + add_header Access-Control-Allow-Credentials true always; + add_header Access-Control-Allow-Headers content-type always; + add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_set_header Referer $host; proxy_set_header Origin $http_origin; proxy_set_header X-Real-IP $remote_addr; @@ -177,13 +205,17 @@ server { location /treasurer// { + if ($request_method = OPTIONS) { add_header Access-Control-Allow-Origin $http_origin always; add_header Access-Control-Allow-Credentials true always; add_header Access-Control-Allow-Headers content-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; - if ($request_method = OPTIONS) { return 200; } + add_header Access-Control-Allow-Origin $http_origin always; + add_header Access-Control-Allow-Credentials true always; + add_header Access-Control-Allow-Headers content-type always; + add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_set_header Referer $host; proxy_set_header Origin $http_origin; proxy_set_header X-Real-IP $remote_addr; @@ -201,13 +233,17 @@ server { location /price// { + if ($request_method = OPTIONS) { add_header Access-Control-Allow-Origin $http_origin always; add_header Access-Control-Allow-Credentials true always; add_header Access-Control-Allow-Headers content-type,authorization,response-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; - if ($request_method = OPTIONS) { return 200; } + add_header Access-Control-Allow-Origin $http_origin always; + add_header Access-Control-Allow-Credentials true always; + add_header Access-Control-Allow-Headers content-type,authorization,response-type always; + add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_set_header Referer $host; proxy_set_header Origin $http_origin; proxy_set_header X-Real-IP $remote_addr; @@ -225,13 +261,17 @@ server { location /feedback// { + if ($request_method = OPTIONS) { add_header Access-Control-Allow-Origin $http_origin always; add_header Access-Control-Allow-Credentials true always; add_header Access-Control-Allow-Headers content-type,response-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; - if ($request_method = OPTIONS) { return 200; } + add_header Access-Control-Allow-Origin $http_origin always; + add_header Access-Control-Allow-Credentials true always; + add_header Access-Control-Allow-Headers content-type,response-type always; + add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_set_header Referer $host; proxy_set_header Origin $http_origin; proxy_set_header X-Real-IP $remote_addr; @@ -249,13 +289,17 @@ server { location /requestquiz// { + if ($request_method = OPTIONS) { add_header Access-Control-Allow-Origin $http_origin always; add_header Access-Control-Allow-Credentials true always; add_header Access-Control-Allow-Headers content-type,response-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; - if ($request_method = OPTIONS) { return 200; } + add_header Access-Control-Allow-Origin $http_origin always; + add_header Access-Control-Allow-Credentials true always; + add_header Access-Control-Allow-Headers content-type,response-type always; + add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_set_header Referer $host; proxy_set_header Origin $http_origin; proxy_set_header X-Real-IP $remote_addr; @@ -273,13 +317,17 @@ server { location /verification/v1.0.0/ { + if ($request_method = OPTIONS) { add_header Access-Control-Allow-Origin $http_origin always; add_header Access-Control-Allow-Credentials true always; add_header Access-Control-Allow-Headers content-type,authorization,response-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; - if ($request_method = OPTIONS) { return 200; } + add_header Access-Control-Allow-Origin $http_origin always; + add_header Access-Control-Allow-Credentials true always; + add_header Access-Control-Allow-Headers content-type,authorization,response-type always; + add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_set_header Referer $host; proxy_set_header Origin $http_origin; proxy_set_header X-Real-IP $remote_addr; @@ -302,13 +350,17 @@ server { location /pena-social-auth-service// { + if ($request_method = OPTIONS) { add_header Access-Control-Allow-Origin $http_origin always; add_header Access-Control-Allow-Credentials true always; add_header Access-Control-Allow-Headers content-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; - if ($request_method = OPTIONS) { return 200; } + add_header Access-Control-Allow-Origin $http_origin always; + add_header Access-Control-Allow-Credentials true always; + add_header Access-Control-Allow-Headers content-type always; + add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_set_header Referer $host; proxy_set_header Origin $http_origin; proxy_set_header X-Real-IP $remote_addr; @@ -333,13 +385,17 @@ server { location /cbrfworker-service-staging// { + if ($request_method = OPTIONS) { add_header Access-Control-Allow-Origin $http_origin always; add_header Access-Control-Allow-Credentials true always; add_header Access-Control-Allow-Headers content-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; - if ($request_method = OPTIONS) { return 200; } + add_header Access-Control-Allow-Origin $http_origin always; + add_header Access-Control-Allow-Credentials true always; + add_header Access-Control-Allow-Headers content-type always; + add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_set_header Referer $host; proxy_set_header Origin $http_origin; proxy_set_header X-Real-IP $remote_addr; @@ -357,13 +413,17 @@ server { location /squiz-amocrm// { + if ($request_method = OPTIONS) { add_header Access-Control-Allow-Origin $http_origin always; add_header Access-Control-Allow-Credentials true always; add_header Access-Control-Allow-Headers content-type,authorization,device,browser,os,devicetype,response-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; - if ($request_method = OPTIONS) { return 200; } + add_header Access-Control-Allow-Origin $http_origin always; + add_header Access-Control-Allow-Credentials true always; + add_header Access-Control-Allow-Headers content-type,authorization,device,browser,os,devicetype,response-type always; + add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_set_header Referer $host; proxy_set_header Origin $http_origin; proxy_set_header X-Real-IP $remote_addr; @@ -378,13 +438,17 @@ server { location /squiz/amocrm/ { + if ($request_method = OPTIONS) { add_header Access-Control-Allow-Origin $http_origin always; add_header Access-Control-Allow-Credentials true always; add_header Access-Control-Allow-Headers content-type,authorization,device,browser,os,devicetype,response-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; - if ($request_method = OPTIONS) { return 200; } + add_header Access-Control-Allow-Origin $http_origin always; + add_header Access-Control-Allow-Credentials true always; + add_header Access-Control-Allow-Headers content-type,authorization,device,browser,os,devicetype,response-type always; + add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_set_header Referer $host; proxy_set_header Origin $http_origin; proxy_set_header X-Real-IP $remote_addr; @@ -396,13 +460,17 @@ server { location /squiz/amocrm/oauth/ { + if ($request_method = OPTIONS) { add_header Access-Control-Allow-Origin $http_origin always; add_header Access-Control-Allow-Credentials true always; add_header Access-Control-Allow-Headers content-type,authorization,device,browser,os,devicetype,response-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; - if ($request_method = OPTIONS) { return 200; } + add_header Access-Control-Allow-Origin $http_origin always; + add_header Access-Control-Allow-Credentials true always; + add_header Access-Control-Allow-Headers content-type,authorization,device,browser,os,devicetype,response-type always; + add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_set_header Referer $host; proxy_set_header Origin $http_origin; proxy_set_header X-Real-IP $remote_addr; @@ -415,13 +483,17 @@ server { location /answer/v1.0.0/ { + if ($request_method = OPTIONS) { add_header Access-Control-Allow-Origin $http_origin always; add_header Access-Control-Allow-Credentials true always; add_header Access-Control-Allow-Headers content-type,x-sessionkey,device,browser,os,devicetype,response-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; - if ($request_method = OPTIONS) { return 200; } + add_header Access-Control-Allow-Origin $http_origin always; + add_header Access-Control-Allow-Credentials true always; + add_header Access-Control-Allow-Headers content-type,x-sessionkey,device,browser,os,devicetype,response-type always; + add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_set_header Referer $host; proxy_set_header Origin $http_origin; proxy_set_header X-Real-IP $remote_addr; @@ -451,13 +523,17 @@ server { location /squiz// { + if ($request_method = OPTIONS) { add_header Access-Control-Allow-Origin $http_origin always; add_header Access-Control-Allow-Credentials true always; add_header Access-Control-Allow-Headers content-type,authorization,device,browser,os,devicetype,response-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; - if ($request_method = OPTIONS) { return 200; } + add_header Access-Control-Allow-Origin $http_origin always; + add_header Access-Control-Allow-Credentials true always; + add_header Access-Control-Allow-Headers content-type,authorization,device,browser,os,devicetype,response-type always; + add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_set_header Referer $host; proxy_set_header Origin $http_origin; proxy_set_header X-Real-IP $remote_addr; @@ -475,13 +551,17 @@ server { location /squizstorer/v1.0.0/ { + if ($request_method = OPTIONS) { add_header Access-Control-Allow-Origin $http_origin always; add_header Access-Control-Allow-Credentials true always; add_header Access-Control-Allow-Headers content-type,authorization,response-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; - if ($request_method = OPTIONS) { return 200; } + add_header Access-Control-Allow-Origin $http_origin always; + add_header Access-Control-Allow-Credentials true always; + add_header Access-Control-Allow-Headers content-type,authorization,response-type always; + add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_set_header Referer $host; proxy_set_header Origin $http_origin; proxy_set_header X-Real-IP $remote_addr;