Skip to content

Commit 7485349

Browse files
author
Andrew Welch
committed
Merge branch 'release/1.0.25'
2 parents 3b3e2f5 + 95e985c commit 7485349

File tree

2 files changed

+10
-0
lines changed

2 files changed

+10
-0
lines changed

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
# Nginx-Craft Changelog
22

3+
## 1.0.25 - 2020.06.15
4+
### Changed
5+
* Route any 404s for `expires.conf` matches back through Craft for handling
6+
37
## 1.0.24 - 2020.05.14
48
### Added
59
* Added `always` to all of the added headers in `security.conf` so that they are added regardless of response code

nginx-partials/expires.conf

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,8 @@ location ~* \.(?:jpg|jpeg|gif|png|ico|cur|gz|svg|svgz|mp3|mp4|ogg|ogv|webm|htc|w
1919
etag off;
2020
expires 1M;
2121
access_log off;
22+
# Route any 404s back through Craft
23+
try_files $uri /index.php?$query_string;
2224
# max-age=2592000 = 1 month in seconds, stale-while-revalidate=86400 = 1 day in seconds
2325
add_header Cache-Control "public, max-age=2592000, must-revalidate, stale-while-revalidate=86400";
2426
}
@@ -28,6 +30,8 @@ location ~* \.(?:css|js)$ {
2830
etag off;
2931
expires 1y;
3032
access_log off;
33+
# Route any 404s back through Craft
34+
try_files $uri /index.php?$query_string;
3135
# max-age=31556952 = 1 year in seconds
3236
add_header Cache-Control "public, max-age=31556952, immutable";
3337
}
@@ -38,6 +42,8 @@ location ~* \.(?:ttf|ttc|otf|eot|woff|woff2)$ {
3842
add_header "Access-Control-Allow-Origin" "*";
3943
expires 1M;
4044
access_log off;
45+
# Route any 404s back through Craft
46+
try_files $uri /index.php?$query_string;
4147
# max-age=2592000 = 1 month in seconds, stale-while-revalidate=86400 = 1 day in seconds
4248
add_header Cache-Control "public, max-age=2592000, must-revalidate, stale-while-revalidate=86400";
4349
}

0 commit comments

Comments
 (0)