mirror of
https://github.com/discourse/discourse.git
synced 2025-02-21 03:19:10 +00:00
FIX: cache all public resources registered by plugins.
Plugins are responsible for expiry
This commit is contained in:
parent
51955e6e78
commit
5551676fef
@ -58,7 +58,7 @@ server {
|
||||
# further more etags are based on the file in nginx not sha of data
|
||||
# use dates, it solves the problem fine even cross server
|
||||
etag off;
|
||||
|
||||
|
||||
# prevent direct download of backups
|
||||
location ^~ /backups/ {
|
||||
internal;
|
||||
@ -79,9 +79,15 @@ server {
|
||||
# asset pipeline enables this
|
||||
gzip_static on;
|
||||
add_header Cache-Control public;
|
||||
# TODO I don't think this break is needed, it just breaks out of rewrite
|
||||
break;
|
||||
}
|
||||
|
||||
location ~ ^/plugins/ {
|
||||
expires 1y;
|
||||
add_header Cache-Control public;
|
||||
}
|
||||
|
||||
location ~ ^/uploads/ {
|
||||
|
||||
# NOTE: it is really annoying that we can't just define headers
|
||||
|
Loading…
x
Reference in New Issue
Block a user