[object Object]

← back to Wallpaperwednesday

deploy: guard live runtime data from rsync --delete

e85d1afb0bc9b51d00b66845b431cb13b73ed8c6 · 2026-09-04 08:32:31 -0700 · Steve Abrams

deploy.sh runs 'rsync -az --delete'. This project's server appends
user-submitted state to a path inside its own deployed tree, and the file
does not exist locally — so a deploy DELETED it on prod outright.

Proven by itemized rsync --dry-run against prod:
  WITHOUT guard: *deleting   <the runtime file>
  WITH guard:    (nothing)

Prod held real data at the time of the fix: fabricfriday 19,
textiletuesday 70, wallpaperwednesday 30 newsletter subscribers.

Found by the new deploy-data-guard-canary, which caught these four after
a hand-rolled sweep missed them. TK-11227.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013mq9RQtVZZEWvreDqqTgv2

Files touched

Diff

commit e85d1afb0bc9b51d00b66845b431cb13b73ed8c6
Author: Steve Abrams <steve@designerwallcoverings.com>
Date:   Fri Sep 4 08:32:31 2026 -0700

    deploy: guard live runtime data from rsync --delete
    
    deploy.sh runs 'rsync -az --delete'. This project's server appends
    user-submitted state to a path inside its own deployed tree, and the file
    does not exist locally — so a deploy DELETED it on prod outright.
    
    Proven by itemized rsync --dry-run against prod:
      WITHOUT guard: *deleting   <the runtime file>
      WITH guard:    (nothing)
    
    Prod held real data at the time of the fix: fabricfriday 19,
    textiletuesday 70, wallpaperwednesday 30 newsletter subscribers.
    
    Found by the new deploy-data-guard-canary, which caught these four after
    a hand-rolled sweep missed them. TK-11227.
    
    Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
    Claude-Session: https://claude.ai/code/session_013mq9RQtVZZEWvreDqqTgv2
---
 .deploy.conf | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/.deploy.conf b/.deploy.conf
index fc50ecd..f71b7cf 100644
--- a/.deploy.conf
+++ b/.deploy.conf
@@ -3,3 +3,10 @@ DEPLOY_HOST=45.61.58.125
 DEPLOY_PATH=/root/Projects/wallpaperwednesday
 HEALTH_URL=http://127.0.0.1:9900/
 INSTALL_CMD="npm ci --production"
+
+# data/subscribers.jsonl is the LIVE newsletter list, appended by the running
+# server when a visitor subscribes. deploy.sh runs `rsync -az --delete`; the file
+# does not exist locally, so without this exclude a deploy DELETES the prod
+# subscriber list outright. Surgical: data/products.json is a build artifact and
+# must keep syncing.
+RSYNC_EXTRA_EXCLUDES="/data/subscribers.jsonl"

← c0b31eb GA4+Meta pixel: inject gtag + fbq into homepage  ·  back to Wallpaperwednesday  ·  TK-11341: add AdSense Auto-Ads loader + ads.txt (revert to r 79c83c8 →