From 1e1b7bd67fc9d6a53bea5e3b5af02ac2a319a16a Mon Sep 17 00:00:00 2001 From: Mikhail Date: Fri, 15 Mar 2024 18:16:27 +0000 Subject: [PATCH] Update default.conf --- default.conf | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/default.conf b/default.conf index 405fbf3..81287bc 100644 --- a/default.conf +++ b/default.conf @@ -111,6 +111,21 @@ server { proxy_pass http://10.6.0.11:59664/; } + 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,authorization always; + add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; + 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 always; + add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; + proxy_pass http://10.6.0.11:9664/; + } + location /answer/ { proxy_set_header Referer $host; proxy_set_header Origin $http_origin;