Private
Public Access
1
0
Files
Kanban/docker-entrypoint.sh
T
Catherine Renelle 6ed0349507 Phase 7: Search, filters, templates, and archive UI
Add full-text card search (PostgreSQL tsvector + GIN index) with navbar
SearchBar, client-side board filters (label/assignee/due date), board
templates (3 system templates + save-as-template API), and archive
toggle for both board listing and board view.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-26 00:42:20 -05:00

39 lines
953 B
Bash

#!/bin/sh
set -e
echo "Waiting for database..."
MAX_RETRIES=30
RETRY=0
while [ $RETRY -lt $MAX_RETRIES ]; do
if npx prisma db push --skip-generate 2>&1; then
echo "Database schema synced successfully."
break
fi
RETRY=$((RETRY + 1))
echo "Database not ready (attempt $RETRY/$MAX_RETRIES), retrying in 3s..."
sleep 3
done
if [ $RETRY -ge $MAX_RETRIES ]; then
echo "ERROR: Could not connect to database after $MAX_RETRIES attempts."
exit 1
fi
echo "Applying RLS policies..."
if psql "$DATABASE_URL" -f ./scripts/setup-rls.sql; then
echo "RLS policies applied successfully."
else
echo "WARNING: Failed to apply RLS policies. Continuing anyway..."
fi
echo "Applying full-text search indexes..."
if psql "$DATABASE_URL" -f ./scripts/setup-search.sql; then
echo "Search indexes applied successfully."
else
echo "WARNING: Failed to apply search indexes. Continuing anyway..."
fi
echo "Starting server..."
exec node server.js