Fix design-vs-implementation gaps found in verification

Critical fixes:
- Wire monitor subsystem to agent startup (was dead code)
- Implement NodeStatus RPC (disk, memory, CPU, runtime version, uptime)
- Deploy respects active=false (sets desired_state=stopped, not always running)

Medium fixes:
- Add Started field to runtime.ContainerInfo, populate from podman inspect
- Populate ComponentInfo.started in status handlers for uptime display
- Add Monitor field to Agent struct for graceful shutdown

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-03-26 12:29:04 -07:00
parent 8f913ddf9b
commit 941dd7003a
7 changed files with 99 additions and 8 deletions

View File

@@ -97,6 +97,9 @@ func (a *Agent) liveCheckServices(ctx context.Context) ([]*mcpv1.ServiceInfo, er
if rc, ok := runtimeByName[containerName]; ok {
ci.ObservedState = rc.State
if !rc.Started.IsZero() {
ci.Started = timestamppb.New(rc.Started)
}
matched[containerName] = true
} else {
ci.ObservedState = "removed"