From: Michael Tremer Date: Tue, 11 Feb 2025 16:21:43 +0000 (+0000) Subject: mirrors: Ask clients to not cache the redirect X-Git-Url: http://git.ipfire.org/gitweb/gitweb.cgi?a=commitdiff_plain;h=9fcf04e53ab3e16c9adcdc36c67ba0a38ae02ba6;p=pbs.git mirrors: Ask clients to not cache the redirect Signed-off-by: Michael Tremer --- diff --git a/src/web/mirrors.py b/src/web/mirrors.py index b16c1d35..4ea0d770 100644 --- a/src/web/mirrors.py +++ b/src/web/mirrors.py @@ -145,6 +145,9 @@ class DownloadsHandler(base.BaseHandler): if not await self.backend.stat(path, stat.S_IFREG): raise tornado.web.HTTPError(404) + # Tell the clients to never cache the redirect + self.set_header("Cache-Control", "no-store") + # Fetch all mirrors for this client mirrors = await self.backend.mirrors.get_mirrors_for_address(self.current_address)