|
@@ -10,21 +10,26 @@ server {
|
|
|
ssl_prefer_server_ciphers on;
|
|
|
ssl_session_timeout 5m;
|
|
|
|
|
|
- add_header Access-Control-Allow-Origin *;
|
|
|
- add_header Access-Control-Allow-Headers X-Requested-With;
|
|
|
- add_header Access-Control-Allow-Methods GET,POST,OPTIONS;
|
|
|
+ add_header 'Access-Control-Allow-Origin' '*';
|
|
|
+ add_header 'Access-Control-Allow-Credentials' 'true' ;
|
|
|
+ add_header 'Access-Control-Allow-Methods' 'GET, POST, OPTIONS';
|
|
|
+ add_header 'Access-Control-Allow-Headers' 'Authorization,Content-Type,Accept,Origin,User-Agent,DNT,Cache-Control,X-Mx-ReqToken,Keep-Alive,X-Requested-With,Pragma,Cache-Control,If-Modified-Since';
|
|
|
|
|
|
charset utf-8;
|
|
|
|
|
|
server_name api-debug.xinyueyouxi.com;
|
|
|
|
|
|
- location /share {
|
|
|
+ location / {
|
|
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
proxy_set_header Remote_addr $remote_addr;
|
|
|
proxy_set_header X-Real_IP $remote_addr;
|
|
|
proxy_set_header Host $host;
|
|
|
+ if ($request_method = 'OPTIONS') {
|
|
|
+ return 200;
|
|
|
+ }
|
|
|
+
|
|
|
|
|
|
- proxy_pass http://172.21.164.128:9092;
|
|
|
+ proxy_pass http://sharesrv2-svc:9092;
|
|
|
}
|
|
|
|
|
|
location /favicon.ico {
|