Files
indee-demo/Dockerfile.seed
Dorian 33190afd08 Fix seeder Dockerfile: remove --ignore-scripts from npm ci
The --ignore-scripts flag prevented esbuild (used by tsx) from
downloading its platform binary, causing the seed scripts to
fail with exit 1 in the Docker container.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-12 12:52:12 +00:00

24 lines
763 B
Docker

# Seeder container — populates the Nostr relay with test profiles,
# reactions, and comments so the dev deployment has content.
#
# Runs once and exits. docker-compose "restart: no" keeps it from looping.
FROM node:20-alpine
WORKDIR /app
# Install dependencies (need full install so tsx/esbuild get their binaries)
COPY package*.json ./
RUN npm ci
# Copy only what the seed scripts need
COPY scripts/ ./scripts/
COPY src/data/testPersonas.ts ./src/data/testPersonas.ts
COPY tsconfig.json ./
# Default env (overridden by docker-compose)
ENV RELAY_URL=ws://relay:8080
ENV ORIGIN=http://localhost:7777
CMD ["sh", "-c", "node scripts/wait-for-relay.mjs && npx tsx scripts/seed-profiles.ts && npx tsx scripts/seed-activity.ts && echo '✅ Seeding complete!'"]