$ErrorActionPreference = "Stop"

Write-Host "[Aegis] 檢查 Docker Desktop 連線..." -ForegroundColor Cyan
docker info | Out-Null

Write-Host "[Aegis] 啟動容器（第一次會較久，會先建置映像）..." -ForegroundColor Cyan
docker compose -f "$PSScriptRoot/docker-compose.yml" up -d --build

Write-Host "[Aegis] 目前服務狀態：" -ForegroundColor Cyan
docker compose -f "$PSScriptRoot/docker-compose.yml" ps

Write-Host ""
Write-Host "啟動完成，可用入口：" -ForegroundColor Green
Write-Host "  - 系統入口:      http://localhost:8080"
Write-Host "  - Swagger:      http://localhost:8080/swagger-ui/index.html"
Write-Host "  - Jitsi:        http://localhost:8443"
Write-Host "  - Adminer:      http://localhost:3306"
Write-Host "  - RedisInsight: http://localhost:6379"
