fix(auth): harden unified diagnostic execution

This commit is contained in:
2026-08-17 16:39:54 +02:00
parent 3ed00ff086
commit 30ee9433dc
20 changed files with 1034 additions and 57 deletions
+14
View File
@@ -97,6 +97,20 @@ func CoreRunning(value string) (bool, error) {
return false, nil
}
// CoreHealthy reports whether core is both running and certified healthy by Compose.
func CoreHealthy(value string) (bool, error) {
statuses, err := parseStatuses(value)
if err != nil {
return false, err
}
for _, item := range statuses {
if item.Service == "core" {
return strings.EqualFold(item.State, "running") && strings.EqualFold(item.Health, "healthy"), nil
}
}
return false, nil
}
// Healthy verifies the full expected Compose service set, including the one-shot model initializer.
func Healthy(value string) error {
statuses, err := parseStatuses(value)