Jul 14 - Using CDN - Fix web CSP
This commit is contained in:
@@ -1396,6 +1396,7 @@ timeout = 30
|
||||
- Backward-compatible: empty URL arrays (older server) → resolver builds the `/static/` URL as before.
|
||||
|
||||
**Operator cutover runbook (after 4b ships + Phase 3 sync exits clean):**
|
||||
- [ ] **CSP:** the web `img-src` must allow the R2 host or the browser blocks presigned image loads. Handled in `app/__init__.py` `set_security_headers` — the R2 endpoint host is derived from `R2_ENDPOINT_URL` and appended to `img-src` automatically when configured (local backend unaffected). If you use a custom R2 domain for presigned URLs, add that host too.
|
||||
- [ ] Confirm `python scripts/migrate_photos_to_r2.py` prints "✅ SAFE" (0 mismatches) and verified count ≥ Phase 0 baseline present-count.
|
||||
- [ ] Maintenance window: run the sync once more (delta) → set `STORAGE_BACKEND=s3` in `.env` → `systemctl restart janitorial-qc`.
|
||||
- [ ] Smoke test: existing web issue/inspection photos load; existing iPad issue photos load; a **new** upload from web and from iPad lands in R2 and renders; generate an inspection PDF + issue PDF with photos.
|
||||
|
||||
Reference in New Issue
Block a user