File size: 1,013 Bytes
5dfbe50
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
#!/bin/bash

# ColPali Hono Proxy Quick Start Script

echo "πŸš€ ColPali Hono Proxy Setup"
echo "=========================="

# Check if .env exists
if [ ! -f .env ]; then
    echo "πŸ“ Creating .env file from template..."
    cp .env.example .env
    echo "⚠️  Please update .env with your configuration"
    echo ""
fi

# Install dependencies if needed
if [ ! -d "node_modules" ]; then
    echo "πŸ“¦ Installing dependencies..."
    npm install
    echo ""
fi

# Check if backend is running
echo "πŸ” Checking backend connection..."
BACKEND_URL=${BACKEND_URL:-http://localhost:7860}
if curl -f -s "$BACKEND_URL/health" > /dev/null; then
    echo "βœ… Backend is reachable at $BACKEND_URL"
else
    echo "⚠️  Warning: Backend at $BACKEND_URL is not responding"
    echo "   Make sure your ColPali backend is running"
fi
echo ""

# Start the server
echo "πŸš€ Starting Hono proxy server..."
echo "   API URL: http://localhost:4000/api"
echo "   Health: http://localhost:4000/health"
echo ""

npm run dev