refactor(agent-pod): merge hub into pi container, drop kubectl-exec spawn step
agent-console complained about the two-step workflow: kubectl exec a script to spawn an agent, separate terminal to watch it. Root cause was hub being a separate Go sidecar with no access to the pi binary or its config, so it could only watch, never trigger. hub.js now runs inside the pi container itself (same filesystem, same PATH) and exposes POST /run, which spawns `pi -p --mode json` directly and streams it over the same /console WebSocket everyone else is already watching. agent-console gained a `run <agent> <prompt>` subcommand that POSTs then watches -- no separate exec step, no separate terminal. Drops the golang:1.25-alpine sidecar container and agent-run-configmap.yaml entirely (both superseded). ConfigMaps regenerated via local-harness/hub/sync-to-homelab.sh instead of hand-copied, so hub.js/config.json/settings.json each have exactly one source of truth.
This commit is contained in:
@@ -1,8 +1,4 @@
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
name: pi-config
|
||||
namespace: agent-pod
|
||||
data:
|
||||
config.json: |
|
||||
{
|
||||
@@ -39,3 +35,7 @@ data:
|
||||
"defaultThinkingLevel": "medium",
|
||||
"theme": "light"
|
||||
}
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
name: pi-config
|
||||
namespace: agent-pod
|
||||
|
||||
Reference in New Issue
Block a user