This repository has been archived on 2022-10-07. You can view files and clone it, but cannot push or open issues or pull requests.
skynet-webportal/docker/nginx/conf.d/include/cors

10 lines
466 B
Plaintext
Raw Normal View History

2020-07-27 15:04:21 +00:00
if ($request_method = 'OPTIONS') {
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';
2020-07-28 09:19:03 +00:00
add_header 'Access-Control-Max-Age' 1728000; # valid for 20 days
2020-07-27 15:04:21 +00:00
add_header 'Content-Type' 'text/plain; charset=utf-8';
add_header 'Content-Length' 0;
return 204;
2020-07-27 15:18:09 +00:00
}