-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathrun.sh
More file actions
33 lines (26 loc) · 1000 Bytes
/
Copy pathrun.sh
File metadata and controls
33 lines (26 loc) · 1000 Bytes
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
#!/bin/bash
# SignalTap FastAPI Backend Runner Script
# This script activates the virtual environment and runs the FastAPI application
echo "🚀 Starting SignalTap FastAPI Backend..."
# Check if virtual environment exists
if [ ! -d ".venv" ]; then
echo "📦 Virtual environment not found. Creating one..."
python -m venv .venv
fi
# Activate virtual environment
echo "🔧 Activating virtual environment..."
source .venv/bin/activate
# Install dependencies if requirements.txt exists
if [ -f "requirements.txt" ]; then
echo "📥 Installing dependencies..."
pip install -r requirements.txt
fi
# Run the FastAPI application
echo "🌐 Starting FastAPI server..."
echo "📖 API Documentation will be available at: http://localhost:8000/docs"
echo "🔍 Interactive API docs at: http://localhost:8000/redoc"
echo "🏥 Health check at: http://localhost:8000/health"
echo ""
echo "Press Ctrl+C to stop the server"
echo ""
uvicorn app.main:app --host 0.0.0.0 --port 8000 --reload