add get_logs tool to manager mcp surface

This commit is contained in:
damocles 2026-05-16 20:28:42 +02:00
parent fca480b86e
commit 1023acf69f
3 changed files with 90 additions and 0 deletions

View file

@ -475,6 +475,17 @@ pub enum ManagerRequest {
#[serde(default)]
ttl_seconds: Option<u64>,
},
/// Fetch recent journal lines for a sub-agent container. hive-c0re
/// runs `journalctl -M <agent> -n <lines> --no-pager` and returns
/// the output as a string. Useful for diagnosing MCP registration
/// failures, startup crashes, and harness errors.
///
/// `lines` defaults to 50 when omitted.
GetLogs {
agent: String,
#[serde(default)]
lines: Option<u32>,
},
}
#[derive(Debug, Clone, Serialize, Deserialize)]
@ -502,4 +513,8 @@ pub enum ManagerResponse {
Recent {
rows: Vec<InboxRow>,
},
/// `GetLogs` result: journal lines for the requested container.
Logs {
content: String,
},
}