# Gradio FastAPI Django Main - Docker Compose Start Script | |
# Based on README.md configuration: Gradio 4.29.0, app.py | |
Write-Host "π¦ Starting Gradio FastAPI Django Main Application" -ForegroundColor Cyan | |
Write-Host "Emoji: π¦" -ForegroundColor Yellow | |
Write-Host "SDK: Gradio 4.29.0" -ForegroundColor Green | |
Write-Host "App File: app.py" -ForegroundColor Blue | |
# Check if Docker is running | |
if (!(Get-Process "Docker Desktop" -ErrorAction SilentlyContinue)) { | |
Write-Host "β Docker Desktop is not running. Please start Docker Desktop first." -ForegroundColor Red | |
exit 1 | |
} | |
# Build and start the containers | |
Write-Host "π¨ Building and starting containers..." -ForegroundColor Cyan | |
docker-compose up --build -d | |
if ($LASTEXITCODE -eq 0) { | |
Write-Host "β Application started successfully!" -ForegroundColor Green | |
Write-Host "π Application is running at: http://localhost:7860" -ForegroundColor Blue | |
Write-Host "π Container status:" -ForegroundColor Yellow | |
docker-compose ps | |
Write-Host "`nπ To view logs: docker-compose logs -f" -ForegroundColor Cyan | |
Write-Host "π To stop: docker-compose down" -ForegroundColor Cyan | |
} else { | |
Write-Host "β Failed to start application. Check the logs:" -ForegroundColor Red | |
docker-compose logs | |
} |