Fix dev-start podman-compose handling

This commit is contained in:
Marco Allegretti 2026-01-31 14:29:51 +01:00
parent 8b904c1919
commit 173bea0ac1

View file

@ -52,7 +52,17 @@ try {
# Start PostgreSQL container
Write-Host "Starting PostgreSQL..."
$composeFile = Join-Path $root 'compose/dev.yml'
podman-compose -f $composeFile up -d 2>$null
$composeExitCode = $LASTEXITCODE
if ($composeExitCode -ne 0) {
podman container exists likwid-postgres 2>$null
$containerExistsExitCode = $LASTEXITCODE
if ($containerExistsExitCode -ne 0) {
throw "Failed to start PostgreSQL via podman-compose (exit code: $composeExitCode)."
}
Write-Host "Warning: podman-compose returned exit code $composeExitCode, but likwid-postgres exists. Continuing."
}
# Wait for PostgreSQL to be ready
$maxWait = 30