-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsetup-backend.ps1
More file actions
26 lines (19 loc) · 974 Bytes
/
setup-backend.ps1
File metadata and controls
26 lines (19 loc) · 974 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
# PowerShell script for Windows setup
Write-Host "🚀 Setting up TRDR Hub LCopilot Backend..." -ForegroundColor Green
# Check if Docker is installed
if (Get-Command docker -ErrorAction SilentlyContinue) {
Write-Host "✅ Docker found. Using Docker setup..." -ForegroundColor Green
# Start services with Docker Compose
docker-compose up -d postgres redis
Write-Host "⏳ Waiting for services to be ready..." -ForegroundColor Yellow
Start-Sleep -Seconds 10
# Run migrations
Write-Host "📊 Running database migrations..." -ForegroundColor Blue
docker-compose exec api alembic upgrade head
# Start the API
Write-Host "🚀 Starting API server..." -ForegroundColor Green
docker-compose up api
} else {
Write-Host "❌ Docker not found. Please install Docker or use manual setup." -ForegroundColor Red
Write-Host "📖 See setup-backend.md for manual setup instructions." -ForegroundColor Yellow
}