Repository navigation
fix(wall): serve the wall page's files with Cache-Control: no-cache - #1736
Merged
Merged
Conversation
heimdall's kiosk kept the old wall.js through a Chromium restart after the wall update deployed: Caddy sent no caching header, so Chromium reused its copy on a freshness it guessed from Last-Modified, and asked for routes that no longer exist. no-cache makes each load revalidate (a 304 when nothing changed), so the page's six-hourly reload picks up a change merged to main, as wall.js intends. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
There was a problem hiding this comment.
🟢 Approval recommended
No active review issues are identified for the dashboard’s static-file cache revalidation change.
No open issues 🎉
What changed in this PR
Updates the wall dashboard’s static-file caching so browser loads revalidate with Caddy, helping the kiosk receive deployed changes rather than reuse stale files.
Changes:
- Adds
Cache-Control: no-cachefor the page, JavaScript, and stylesheet; API handles remain unchanged. - Documents the six-hour reload behavior and how to trigger an earlier load.
- Records the stale-cache incident and caching fix in the changelog.
| File | Description |
|---|---|
| stacks/sensitive/README.md | Explains automatic refreshes and restarting Chromium for an earlier load. |
| stacks/sensitive/Caddyfile | Adds revalidation headers to the wall dashboard’s static-file handler. |
| docs/changelog.md | Records the caching fix and the kiosk incident that prompted it. |
Review effort: Balanced
# Conflicts: # docs/changelog.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changed
wall.matrix.elysium's static handle (the page,wall.js,wall.css) now sendsCache-Control: no-cache, so each load revalidates with Caddy (a 304 when nothing changed) instead of reusing the browser's copy. The API handles are unchanged; the page already fetches them withcache: "no-store".Why
After #1732 deployed to
trinityatc5374a15,heimdall's kiosk kept the oldwall.jsthrough a Chromium restart. Caddy's log showed it fetched neither/norwall.js, and kept asking for the removed/api/q/rtt,/api/ha/office_lightand/api/ha/dogs(404). Caddy sent no caching header, so Chromium kept its copy on a freshness it guessed fromLast-Modified, which for files weeks old is days. Clearing itsCache_Dataand restarting it fixed the screen by hand. Without this header,wall.js's six-hourly reload, meant to bring in changes merged tomain, can't do that.Blast radius
trinity's Caddy,wall.matrix.elysiumonly. If wrong, the page loads as before, or costs one extra conditional request per file per load.secrets/*.sops.yamlVerification
python scripts/check_docs.py:docs OK../scripts/lint.sh: passed, 11 skipped (no Docker on this host).caddy validateandmake validatewere not run locally; CI's pinned Caddy checks the file.Not yet deployed. After deploy:
curl -sI https://wall.matrix.elysium/wall.jsshould showCache-Control: no-cache.make validatepassesDeployed to the lab and confirmed working
Docs updated (
docs/, service README, ordocs/roadmap.md)🤖 Generated with Claude Code