mirror of
https://github.com/kuaifan/dootask.git
synced 2025-12-15 21:32:49 +00:00
fix: 修复客户度右键复制图片失败的情况
This commit is contained in:
parent
a19cf0e1c3
commit
9633f7644e
@ -38,6 +38,26 @@ server {
|
||||
try_files $uri @laravels;
|
||||
}
|
||||
|
||||
location ~* \.(jpe?g|png|gif|webp|svg|ico|bmp)$ {
|
||||
add_header Access-Control-Allow-Origin "http://localhost:2222" always;
|
||||
add_header Access-Control-Allow-Methods "GET, OPTIONS" always;
|
||||
add_header Access-Control-Allow-Headers "DNT,User-Agent,X-Requested-With,If-Modified-Since,Cache-Control,Content-Type,Range,Authorization" always;
|
||||
add_header Access-Control-Allow-Credentials "true" always;
|
||||
|
||||
if ($request_method = 'OPTIONS') {
|
||||
add_header Access-Control-Allow-Origin "http://localhost:2222";
|
||||
add_header Access-Control-Allow-Methods "GET, OPTIONS";
|
||||
add_header Access-Control-Allow-Headers "DNT,User-Agent,X-Requested-With,If-Modified-Since,Cache-Control,Content-Type,Range,Authorization";
|
||||
add_header Access-Control-Allow-Credentials "true";
|
||||
add_header Access-Control-Max-Age 1728000;
|
||||
add_header Content-Type "text/plain; charset=utf-8";
|
||||
add_header Content-Length 0;
|
||||
return 204;
|
||||
}
|
||||
|
||||
try_files $uri @laravels;
|
||||
}
|
||||
|
||||
location ~ \.well-known{
|
||||
allow all;
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user