Skip to content

Commit

Permalink
Add no cache header for downloads from GCS
Browse files Browse the repository at this point in the history
  • Loading branch information
nikochiko committed Aug 15, 2024
1 parent 3ed787f commit 3c40079
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion routers/static_pages.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ def serve_static_file(request: Request) -> Response | None:
status_code=HTTP_308_PERMANENT_REDIRECT,
)
html_url = bucket.blob(gcs_path + ".html").public_url
r = requests.get(html_url)
r = requests.get(html_url, headers={"Cache-Control": "no-cache"})
if r.ok:
html = r.content.decode()
# replace sign in button with user's name if logged in
Expand Down

0 comments on commit 3c40079

Please sign in to comment.