Spaces:
Build error
Build error
| # ============================================ | |
| # AudioForge - Quick Demo Launch | |
| # ============================================ | |
| # Fast startup for live demonstrations | |
| # Colors | |
| $ESC = [char]27 | |
| $GREEN = "$ESC[32m" | |
| $CYAN = "$ESC[36m" | |
| $MAGENTA = "$ESC[35m" | |
| $YELLOW = "$ESC[33m" | |
| $RESET = "$ESC[0m" | |
| $BOLD = "$ESC[1m" | |
| Clear-Host | |
| Write-Host "" | |
| Write-Host "${CYAN}${BOLD}βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ${RESET}" | |
| Write-Host "${CYAN}${BOLD}β β${RESET}" | |
| Write-Host "${CYAN}${BOLD}β ${MAGENTA}π΅ AUDIOFORGE π΅${CYAN} β${RESET}" | |
| Write-Host "${CYAN}${BOLD}β β${RESET}" | |
| Write-Host "${CYAN}${BOLD}β ${RESET}Open-Source Text-to-Music Generation Platform${CYAN} β${RESET}" | |
| Write-Host "${CYAN}${BOLD}β β${RESET}" | |
| Write-Host "${CYAN}${BOLD}β ${GREEN}π QUICK DEMO LAUNCHER π${CYAN} β${RESET}" | |
| Write-Host "${CYAN}${BOLD}β β${RESET}" | |
| Write-Host "${CYAN}${BOLD}βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ${RESET}" | |
| Write-Host "" | |
| Write-Host "${CYAN}[1/5]${RESET} Checking Docker..." -NoNewline | |
| try { | |
| docker ps | Out-Null | |
| Write-Host " ${GREEN}β${RESET}" | |
| } catch { | |
| Write-Host " ${RED}β${RESET}" | |
| Write-Host "${RED}Error: Docker is not running. Please start Docker Desktop.${RESET}" | |
| exit 1 | |
| } | |
| Write-Host "${CYAN}[2/5]${RESET} Stopping any existing AudioForge containers..." -NoNewline | |
| docker-compose -f docker-compose.dev.yml down 2>$null | Out-Null | |
| Write-Host " ${GREEN}β${RESET}" | |
| Write-Host "${CYAN}[3/5]${RESET} Starting database services..." -NoNewline | |
| docker-compose -f docker-compose.dev.yml up -d postgres redis 2>&1 | Out-Null | |
| Start-Sleep -Seconds 10 | |
| Write-Host " ${GREEN}β${RESET}" | |
| Write-Host "${CYAN}[4/5]${RESET} Starting backend API..." -NoNewline | |
| docker-compose -f docker-compose.dev.yml up -d backend 2>&1 | Out-Null | |
| Start-Sleep -Seconds 15 | |
| Write-Host " ${GREEN}β${RESET}" | |
| Write-Host "${CYAN}[5/5]${RESET} Starting frontend..." -NoNewline | |
| docker-compose -f docker-compose.dev.yml up -d frontend 2>&1 | Out-Null | |
| Start-Sleep -Seconds 10 | |
| Write-Host " ${GREEN}β${RESET}" | |
| Write-Host "" | |
| Write-Host "${GREEN}${BOLD}βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ${RESET}" | |
| Write-Host "${GREEN}${BOLD} π DEMO IS READY! π${RESET}" | |
| Write-Host "${GREEN}${BOLD}βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ${RESET}" | |
| Write-Host "" | |
| Write-Host "${BOLD}${CYAN}π± Access Points:${RESET}" | |
| Write-Host " ${BOLD}Frontend:${RESET} ${GREEN}http://localhost:3000${RESET}" | |
| Write-Host " ${BOLD}Backend API:${RESET} ${GREEN}http://localhost:8001${RESET}" | |
| Write-Host " ${BOLD}API Docs:${RESET} ${GREEN}http://localhost:8001/docs${RESET}" | |
| Write-Host "" | |
| Write-Host "${BOLD}${YELLOW}π― Demo Script:${RESET}" | |
| Write-Host " 1. Open ${CYAN}http://localhost:3000${RESET}" | |
| Write-Host " 2. Enter prompt: ${GREEN}'Upbeat electronic dance music with heavy bass'${RESET}" | |
| Write-Host " 3. Click ${CYAN}'Generate Music'${RESET}" | |
| Write-Host " 4. Show ${CYAN}API documentation${RESET} at http://localhost:8001/docs" | |
| Write-Host "" | |
| Write-Host "${BOLD}${MAGENTA}π Container Status:${RESET}" | |
| docker-compose -f docker-compose.dev.yml ps | |
| Write-Host "" | |
| Write-Host "${YELLOW}π‘ Useful Commands:${RESET}" | |
| Write-Host " View logs: ${CYAN}docker-compose -f docker-compose.dev.yml logs -f${RESET}" | |
| Write-Host " Stop demo: ${CYAN}docker-compose -f docker-compose.dev.yml down${RESET}" | |
| Write-Host " Restart: ${CYAN}docker-compose -f docker-compose.dev.yml restart${RESET}" | |
| Write-Host "" | |