Files
byrachel/docker-entrypoint.sh
T
2026-07-24 11:34:00 -03:00

13 lines
256 B
Bash

#!/bin/sh
set -e
DB_FILE="/app/data/db.sqlite"
# If DB doesn't exist or is empty, seed it
if [ ! -f "$DB_FILE" ] || [ ! -s "$DB_FILE" ]; then
echo "Database not found, seeding from schema..."
cp /app/seed/db.sqlite "$DB_FILE"
fi
exec node server.js