30 lines
1.1 KiB
Plaintext
30 lines
1.1 KiB
Plaintext
server {
|
|
listen 3002;
|
|
server_name localhost;
|
|
set $appsRoot "/home/ijl/ijl/apps";
|
|
root $appsRoot;
|
|
|
|
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';
|
|
index index.html index.htm;
|
|
alias "$appsRoot/uds-middle/dist/";
|
|
}
|
|
|
|
|
|
location /static/ {
|
|
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';
|
|
alias "$appsRoot/";
|
|
}
|
|
|
|
error_page 500 502 503 504 /50x.html;
|
|
location = /50x.html {
|
|
add_header 'Access-Control-Allow-Origin' '*';
|
|
root html;
|
|
}
|
|
} |