This repository was archived by the owner on May 19, 2026. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathstart_app.sh
More file actions
executable file
·49 lines (40 loc) · 1.6 KB
/
Copy pathstart_app.sh
File metadata and controls
executable file
·49 lines (40 loc) · 1.6 KB
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
41
42
43
44
45
46
47
48
49
#!/bin/bash
# WhisperForge Startup Script
echo "🚀 Starting WhisperForge v3.0.0 with real Supabase credentials..."
# Auto-load environment variables from .env if present
if [ -f .env ]; then
set -a
# shellcheck disable=SC1091
source .env
set +a
fi
# Check for required environment variables
if [ -z "$SUPABASE_URL" ] || [ -z "$SUPABASE_ANON_KEY" ]; then
echo "❌ Missing required environment variables:"
echo " Please set SUPABASE_URL and SUPABASE_ANON_KEY before running this script."
echo " Example:"
echo " export SUPABASE_URL='<your-supabase-url>'"
echo " export SUPABASE_ANON_KEY='<your-supabase-anon-key>'"
exit 1
fi
ENVIRONMENT="${1:-${ENVIRONMENT:-development}}"
export ENVIRONMENT
if [ "$ENVIRONMENT" = "production" ]; then
export DEBUG="${DEBUG:-false}"
export LOG_LEVEL="${LOG_LEVEL:-INFO}"
else
export DEBUG="${DEBUG:-true}"
export LOG_LEVEL="${LOG_LEVEL:-DEBUG}"
fi
echo "Running in $ENVIRONMENT mode"
echo "✅ Environment variables set"
echo "🔗 Supabase URL: $SUPABASE_URL"
echo "🔑 Supabase Key: ${SUPABASE_ANON_KEY:0:20}..."
# Test Supabase connection
echo "🧪 Testing Supabase connection..."
python -c "from core.supabase_integration import get_supabase_client; client = get_supabase_client(); print('✅ Supabase connection successful!' if client.test_connection() else '❌ Connection failed')"
# Start Streamlit app with correct file (app_simple.py is the main app)
echo "🌐 Starting WhisperForge v3.0.0 on http://localhost:8501"
echo "📝 Press Ctrl+C to stop the app"
echo ""
streamlit run app_simple.py --server.port 8501 --server.address 0.0.0.0