Compare commits

...

2 Commits

Author SHA1 Message Date
kitos 38285f885c fix: TypeScript errors blocking production build
- Replace process.env.NODE_ENV with import.meta.env.DEV (Vite compatible)
- Fix undefined not assignable to boolean|null with nullish coalescing
2026-02-10 16:18:34 +01:00
kitos cc0bbdf797 fix: auto-detect Docker API version to avoid client/server mismatch 2026-02-10 16:14:21 +01:00
3 changed files with 9 additions and 2 deletions
+1 -1
View File
@@ -62,7 +62,7 @@ export default class ErrorBoundary extends Component<Props, State> {
return to the dashboard.
</p>
{process.env.NODE_ENV === "development" && this.state.error && (
{import.meta.env.DEV && this.state.error && (
<details className="mt-4 w-full text-left">
<summary className="cursor-pointer text-sm text-gray-500 hover:text-gray-300">
Error details
@@ -294,7 +294,7 @@ export default function DetectionRuleChecklist({ testId, user, canEdit }: Props)
className="flex-1 rounded border border-gray-700 bg-gray-900 px-2 py-1.5 text-xs text-gray-200 placeholder-gray-500 focus:border-indigo-500 focus:outline-none"
/>
<button
onClick={() => handleNotesSave(rule.id, rule.triggered)}
onClick={() => handleNotesSave(rule.id, rule.triggered ?? null)}
disabled={evaluateMutation.isPending}
className="shrink-0 rounded bg-indigo-600 px-2 py-1.5 text-xs font-medium text-white hover:bg-indigo-500 disabled:opacity-50"
>
+7
View File
@@ -69,6 +69,13 @@ else
fi
print_ok "Docker Compose found ($COMPOSE_CMD)"
# Auto-detect Docker API version to avoid client/server mismatch
DOCKER_SERVER_API=$(docker version --format '{{.Server.APIVersion}}' 2>/dev/null || echo "")
if [ -n "$DOCKER_SERVER_API" ]; then
export DOCKER_API_VERSION="$DOCKER_SERVER_API"
print_info "Docker API version: $DOCKER_SERVER_API"
fi
# ── 2. Setup .env file ──────────────────────────────────────────────
print_header "Environment configuration"