Fix proxy caching config additions in terms of HSTS

See tootsuite/mastodon#8487
This commit is contained in:
Eugen Rochko 2018-08-28 00:05:52 +02:00 committed by GitHub
parent eabfcc9122
commit 81b77f7761
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 1 deletions

View File

@ -158,12 +158,13 @@ index 0b50542..1d3fac6 100644
+ proxy_cache_valid 200 7d;
+ proxy_cache_use_stale error timeout updating http_500 http_502 http_503 http_504;
+ add_header X-Cached $upstream_cache_status;
+ add_header Strict-Transport-Security "max-age=31536000";
+
tcp_nodelay on;
}
```
The /var/cache/nginx directory is going to be kept at around 1GB at most, feel free to adjust those values as you see fit. The proxy cache in this case will only cache server responses that do not contain any session data. At the time of writing, these are primarily webfinger and host-meta responses as well as individual statuses in ActivityPub format.
The /var/cache/nginx directory is going to be kept at around 1GB at most, feel free to adjust those values as you see fit. The proxy cache in this case will only cache server responses that do not contain any session data. At the time of writing, these are primarily webfinger and host-meta responses as well as individual statuses in ActivityPub format.
## Using a separate Redis for the Rails cache