Add docker-entrypoint.sh

This commit is contained in:
Zac Gaetano 2026-04-04 22:40:47 -04:00
parent cb876f47a8
commit 0a873c3e54

25
docker-entrypoint.sh Normal file
View file

@ -0,0 +1,25 @@
#!/bin/bash
set -e
echo "Starting Claude Persistent Agent..."
# Ensure claude code is available
if ! command -v claude &> /dev/null; then
echo "Claude Code not found, installing..."
npm install -g @anthropic-ai/claude-code
fi
# Initialize backend
cd /app
# Ensure required directories exist
mkdir -p /app/data /app/logs /app/tasks
# Initialize database
python -c "from backend.main import init_db; init_db()"
echo "Database initialized"
echo "Starting services..."
# Execute the main command (supervisord)
exec "$@"