Summary
The AgentCardSyncReconciler watches Deployment and StatefulSet to auto-create AgentCard CRs for workloads with kagenti.io/type: agent + protocol labels. It does not watch Sandbox (agents.x-k8s.io/v1alpha1), so Sandbox-deployed agents never get an AgentCard auto-created.
Impact
With featureFlags.agentSandbox: true (intended default), Sandbox is the recommended workload type in the UI. Agents deployed as Sandbox are not discoverable via A2A protocol because no AgentCard exists for them.
Required Changes
- Add a third controller registration in
SetupWithManager (similar to the Deployment/StatefulSet adapter pattern) using SandboxCRDExists() guard
- Add a
ReconcileSandbox method that extracts labels from spec.podTemplate.metadata.labels via unstructured access
- Pass the Sandbox GVK to
ensureAgentCard
- Add RBAC marker for
agents.x-k8s.io sandboxes
Reference
Acceptance Criteria
Summary
The
AgentCardSyncReconcilerwatches Deployment and StatefulSet to auto-createAgentCardCRs for workloads withkagenti.io/type: agent+ protocol labels. It does not watch Sandbox (agents.x-k8s.io/v1alpha1), so Sandbox-deployed agents never get an AgentCard auto-created.Impact
With
featureFlags.agentSandbox: true(intended default), Sandbox is the recommended workload type in the UI. Agents deployed as Sandbox are not discoverable via A2A protocol because no AgentCard exists for them.Required Changes
SetupWithManager(similar to the Deployment/StatefulSet adapter pattern) usingSandboxCRDExists()guardReconcileSandboxmethod that extracts labels fromspec.podTemplate.metadata.labelsvia unstructured accessensureAgentCardagents.x-k8s.iosandboxesReference
SandboxCRDExistspatternagentruntime_controller.gofor the canonical Sandbox watch setupAcceptance Criteria
kagenti.io/type: agent+ protocol labels gets AgentCard auto-created