chore: sync GovOPlaN module split state

This commit is contained in:
2026-07-10 12:51:22 +02:00
parent 41528f1947
commit 63ff9a3366
20 changed files with 1151 additions and 0 deletions
+58
View File
@@ -0,0 +1,58 @@
import { apiFetch, type ApiSettings } from "@govoplan/core-webui";
export type OpsCheck = {
id: string;
label: string;
state: "ok" | "warning" | "error" | string;
detail: string;
readiness_critical?: boolean;
};
export type OpsDeploymentProfile = {
id: string;
name: string;
current: boolean;
components: string[];
fit: string;
};
export type OpsSizingAssumption = {
area: string;
baseline: string;
scale_trigger: string;
operator_note: string;
};
export type OpsStatus = {
summary: {
app_env: string;
active_profile: string;
module_count: number;
celery_enabled: boolean;
celery_queues: string[];
redis_url: string;
maintenance_mode: {
enabled: boolean;
message?: string | null;
};
database_url: string;
file_storage_backend: string;
};
readiness: {
ready: boolean;
profile: string;
blockers: Array<{
id: string;
label: string;
state: string;
detail: string;
}>;
};
checks: OpsCheck[];
deployment_profiles: OpsDeploymentProfile[];
sizing: OpsSizingAssumption[];
};
export function fetchOpsStatus(settings: ApiSettings): Promise<OpsStatus> {
return apiFetch(settings, "/api/v1/ops/status");
}