cors 2
This commit is contained in:
parent
3644e1332c
commit
137bdaef13
21
80.conf
21
80.conf
@ -2,20 +2,13 @@ server {
|
|||||||
listen 80;
|
listen 80;
|
||||||
server_name inno-ijl.ru;
|
server_name inno-ijl.ru;
|
||||||
# index index.php index.html index.htm index.nginx-debian.html;
|
# index index.php index.html index.htm index.nginx-debian.html;
|
||||||
location / {
|
|
||||||
|
location /api {
|
||||||
add_header 'Access-Control-Allow-Origin' '*';
|
add_header 'Access-Control-Allow-Origin' '*';
|
||||||
add_header 'Access-Control-Allow-Methods' 'GET, POST, OPTIONS';
|
add_header 'Access-Control-Allow-Methods' 'GET, POST, OPTIONS';
|
||||||
add_header 'Access-Control-Allow-Headers' 'DNT,User-Agent,X-Requested-With,If-Modified-Since,Cache-Control,Content-Type,Range';
|
add_header 'Access-Control-Allow-Headers' 'DNT,User-Agent,X-Requested-With,If-Modified-Since,Cache-Control,Content-Type,Range';
|
||||||
add_header 'Access-Control-Expose-Headers' 'Content-Length,Content-Range';
|
add_header 'Access-Control-Expose-Headers' 'Content-Length,Content-Range';
|
||||||
proxy_pass http://89.223.94.192:8079/;
|
proxy_pass http://backend;
|
||||||
}
|
|
||||||
|
|
||||||
location /api {
|
|
||||||
# add_header 'Access-Control-Allow-Origin' '*';
|
|
||||||
add_header 'Access-Control-Allow-Methods' 'GET, POST, OPTIONS';
|
|
||||||
add_header 'Access-Control-Allow-Headers' 'DNT,User-Agent,X-Requested-With,If-Modified-Since,Cache-Control,Content-Type,Range';
|
|
||||||
add_header 'Access-Control-Expose-Headers' 'Content-Length,Content-Range';
|
|
||||||
proxy_pass http://backend;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
location /multystub/ {
|
location /multystub/ {
|
||||||
@ -25,6 +18,14 @@ server {
|
|||||||
add_header 'Access-Control-Expose-Headers' 'Content-Length,Content-Range';
|
add_header 'Access-Control-Expose-Headers' 'Content-Length,Content-Range';
|
||||||
proxy_pass http://multystub/;
|
proxy_pass http://multystub/;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
location / {
|
||||||
|
add_header 'Access-Control-Allow-Origin' '*';
|
||||||
|
add_header 'Access-Control-Allow-Methods' 'GET, POST, OPTIONS';
|
||||||
|
add_header 'Access-Control-Allow-Headers' 'DNT,User-Agent,X-Requested-With,If-Modified-Since,Cache-Control,Content-Type,Range';
|
||||||
|
add_header 'Access-Control-Expose-Headers' 'Content-Length,Content-Range';
|
||||||
|
proxy_pass http://89.223.94.192:8079/;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
server {
|
server {
|
||||||
|
Loading…
Reference in New Issue
Block a user