Files
rack-planner/docker-entrypoint.sh

18 lines
460 B
Bash
Raw Normal View History

#!/bin/sh
set -e
echo "[entrypoint] RackMapper starting..."
# Ensure the data directory exists and is writable
mkdir -p /app/data
echo "[entrypoint] Data directory: $(ls -la /app/data)"
# Run migrations (creates the SQLite file if it doesn't exist)
echo "[entrypoint] Running database migrations..."
npx prisma migrate deploy
echo "[entrypoint] Migrations complete."
# Start the server
echo "[entrypoint] Starting server..."
exec node dist/server/index.js