guix-commits
[Top][All Lists]
Advanced

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

02/02: nginx: mirror: Override the 'Cache-Control' header of hydra.gnu.o


From: Ludovic Courtès
Subject: 02/02: nginx: mirror: Override the 'Cache-Control' header of hydra.gnu.org.
Date: Wed, 16 Mar 2016 14:53:11 +0000

civodul pushed a commit to branch master
in repository maintenance.

commit e8f216be69319c2e22d0bd76588976baf9beb8a0
Author: Ludovic Courtès <address@hidden>
Date:   Wed Mar 16 15:52:25 2016 +0100

    nginx: mirror: Override the 'Cache-Control' header of hydra.gnu.org.
---
 hydra/nginx/mirror-locations.conf |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)

diff --git a/hydra/nginx/mirror-locations.conf 
b/hydra/nginx/mirror-locations.conf
index 5370b3c..41695e3 100644
--- a/hydra/nginx/mirror-locations.conf
+++ b/hydra/nginx/mirror-locations.conf
@@ -62,8 +62,14 @@ location ~ \.narinfo$ {
     proxy_cache_valid 200 90d;  # cache hits for 3 months.
     proxy_cache_valid any 1h;   # cache misses/others for 1h.
 
+    # Use the above TTLs, not those advertised by hydra.gnu.org.
+    proxy_ignore_headers Expires Cache-Control;
+
     # Add 'Expires' and 'Cache-Control' response headers so clients
     # such as 'guix substitute' know how long they can cache it.
+    # Override the headers coming from hydra.gnu.org.
+    proxy_hide_header    Expires;
+    proxy_hide_header    Cache-Control;
     expires 7d;
 
     proxy_ignore_client_abort on;



reply via email to

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