guix-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

01/01: hydra: berlin: Cache /static requests.


From: Ludovic Courtès
Subject: 01/01: hydra: berlin: Cache /static requests.
Date: Wed, 7 Nov 2018 13:34:25 -0500 (EST)

civodul pushed a commit to branch master
in repository maintenance.

commit e9119639b1a609bfc36b8b7789b8cdf007cc45dc
Author: Ludovic Courtès <address@hidden>
Date:   Wed Nov 7 19:33:19 2018 +0100

    hydra: berlin: Cache /static requests.
    
    * hydra/nginx/berlin-locations.conf (/static): New block.
---
 hydra/nginx/berlin-locations.conf | 13 +++++++++++++
 1 file changed, 13 insertions(+)

diff --git a/hydra/nginx/berlin-locations.conf 
b/hydra/nginx/berlin-locations.conf
index ba40176..4766677 100644
--- a/hydra/nginx/berlin-locations.conf
+++ b/hydra/nginx/berlin-locations.conf
@@ -6,6 +6,19 @@ location / {
     proxy_pass http://localhost:8081;
 }
 
+location /static {
+    proxy_pass http://localhost:8081;
+
+    # Let browsers cache this for a while.
+    expires 10d;
+
+    # Cache quite aggressively.
+    proxy_cache static;
+    proxy_cache_valid 200 5d;
+    proxy_cache_valid any 10m;
+    proxy_ignore_client_abort on;
+}
+
 location = /berlin.guixsd.org-export.pub {
     root @WWWROOT@;
 }



reply via email to

[Prev in Thread] Current Thread [Next in Thread]