Monorepo for Aesthetic.Computer aesthetic.computer
4
fork

Configure Feed

Select the types of activity you want to include in your feed.

system/backend/backfill-sayings.mjs: document working --env-file run

The original "cd system && node ..." run command assumed system/.env
exists, but it doesn't — creds live in the vault. Updated the header
with the actual two --env-file invocation and a slim-install recipe
for the deps, after running the backfill end-to-end (307 mp3s
indexed, 25 jeffrey + 282 unknown-provider pre-stamping).

+14 -4
+14 -4
system/backend/backfill-sayings.mjs
··· 9 9 // keyed on cacheKey, so re-running won't duplicate them. Live ledger 10 10 // rows written by say.js (no `_backfill` field) are unaffected. 11 11 // 12 - // Env (from system/.env): 12 + // Env: 13 13 // ART_ENDPOINT, ART_KEY, ART_SECRET, ART_SPACE_NAME — DO Spaces creds 14 14 // (falls back to DO_SPACES_ENDPOINT/KEY/SECRET if ART_* missing) 15 15 // MONGODB_CONNECTION_STRING, MONGODB_NAME — Mongo creds ··· 17 17 // DRY_RUN "true" to scan + log without writing 18 18 // CONCURRENCY default 8 (parallel HEAD requests) 19 19 // 20 - // Run from repo root: 21 - // cd system && node backend/backfill-sayings.mjs 22 - // PREFIX=tts-cache/jeffrey/ DRY_RUN=true node backend/backfill-sayings.mjs 20 + // Run (deps live in vault env files; ART_* in vault/.env, MONGODB_* in vault/lith/.env): 21 + // cd system 22 + // node --env-file=../aesthetic-computer-vault/.env \ 23 + // --env-file=../aesthetic-computer-vault/lith/.env \ 24 + // backend/backfill-sayings.mjs 25 + // 26 + // Dry-run jeffrey only: 27 + // DRY_RUN=true PREFIX=tts-cache/jeffrey/ node --env-file=... backend/backfill-sayings.mjs 28 + // 29 + // First-time deps (system/node_modules may be stale; slim install works): 30 + // mkdir -p backend/.backfill-deps && cd backend/.backfill-deps 31 + // echo '{"type":"module","dependencies":{"@aws-sdk/client-s3":"*","mongodb":"*","dotenv":"*"}}' > package.json 32 + // npm install && cd .. && ln -sf .backfill-deps/node_modules node_modules 23 33 24 34 import { S3Client, ListObjectsV2Command, HeadObjectCommand } from "@aws-sdk/client-s3"; 25 35 import { config } from "dotenv";