Cache successful static images without caching missing-file errors
This commit is contained in:
parent
b892a4150a
commit
25e0f87d97
@ -4,7 +4,7 @@ location ^~ /images/illustrations/ {
|
|||||||
if ($uri !~ "^/images/illustrations/[a-f0-9]{64}\.(webp|png|jpg|gif)$") { return 404; }
|
if ($uri !~ "^/images/illustrations/[a-f0-9]{64}\.(webp|png|jpg|gif)$") { return 404; }
|
||||||
try_files $uri =404;
|
try_files $uri =404;
|
||||||
etag on;
|
etag on;
|
||||||
add_header Cache-Control "public, max-age=31536000, immutable" always;
|
add_header Cache-Control "public, max-age=31536000, immutable";
|
||||||
add_header X-Content-Type-Options nosniff always;
|
add_header X-Content-Type-Options nosniff always;
|
||||||
add_header X-Illustration-Delivery static always;
|
add_header X-Illustration-Delivery static always;
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user