The platform's agent runtime is an optional component, on by default
(platform.agents in agentlab.yaml; headlessly:
agentlab configure --defaults --agents=false). When enabled, the chart's
kagent component installs kagent API v2 (api.kagent.dev/v1alpha3) with
the platform's Substrate: every agent is an AgentTemplate paired by an
Agent of the same name with the platform's Go ADK Harness kagent
(spec.templateRef, spec.harnessRef; the connectivity chart renders the
Harness and digest-pinned runtime image), compiled
by the controller into a golden snapshot and run as a Substrate actor; a
conversation is a Session of the Agent, its turns A2A messages through the
edge as the signed-in person (docs/platform.md "Dev channel" and
"Substrate"). There is no per-agent Deployment or pod; the Agent of this
line is a pairing, not the 0.x runtime CR of the same kind name.
Agent delivery runs through Flux on every installation. An agent is a
HelmRelease of the Generic agent chart
in the kagent namespace, rendering from the namespace's shared
OCIRepository agent that tracks the chart at 1.x; the platform chart's
bundled engine renders it as the tenant ServiceAccount kagent-flux (the
connectivity chart's kagent.fluxServiceAccountName). One release renders:
- the
AgentTemplatenamed after the release —spec.description,spec.systemPrompt,spec.modelConfig.name,spec.skills[], the annotationsui.giantswarm.io/display-nameandui.giantswarm.io/icon-url; - the
Agentnamed after the release, pairing that template (spec.templateRef) with the Harnessagent.harnessnames (spec.harnessRef, defaultkagent); an Agent whose Harness does not exist is created and never becomes Ready (ResolvedRefs=False); - unless the toolset is exactly
["preset:none"], oneRemoteMCPServernamed after the agent that points at muster (muster.url) and carries the toolset as the staticX-Muster-Toolsetheader (spec.headersFrom, the selectors joined by,), labelledkagent.dev/discovery: disabled; the template binds it as its tools. A release without atoolsetvalue renders the server without the header — implicit full access, the way agents that predate toolsets look.
The HelmRelease's values.toolset is the stable anchor of the toolset; skills
are {name, git: {url, commit}, path} or {name, oci: <ref@sha256:…>}
entries pinned at write time (the CRD refuses a branch, a tag or a short SHA).
Two writers put the same two Flux objects there, and the proofs use both:
- agent-manager as the signed-in person — the platform path. Backstage's
create flow and every MCP client call
x_agent-manager_create_agentthrough muster; agent-manager pins the skills (list_skillsreports the head commits;update_agentwithrefreshSkillsre-pins), validates the values against the chart'svalues.schema.json, writes the HelmRelease (and the OCIRepository when the namespace has none) with the field manageragent-manageras the caller (requestedBy), and reads readiness back from the Agent's status (get_agent_status:ready | progressing | failed— the last with the condition's message). - a HelmRelease applied directly — the operator's kubectl path, the same objects by hand.
In the lab both are one helper (internal/lab/agent.go): readyAgent
writes an agentSpec through an agentWriter (agentManagerWriter on a
muster session, portalAgentManagerWriter through the portal's muster
backend, helmReleaseWriter directly) and waits with waitAgentReady until
the Agent, on the platform Harness, reports Ready on the desired revision —
or fails fast with the reason when the release's render is refused, an Agent
condition is False for good, or the Agent references another Harness.
removeAgent takes the release and whatever render is left. Every agent
proof — agents-test, toolsets-test, models-test's turn,
backstage-test's own agent — creates its agents this way; skills-test
alone writes a raw AgentTemplate and its Agent, on purpose: it is the
golden-boot diagnostic below the chart (a private fixture's credentialRef,
the control boot without the skill).
Agents run against the kagent namespace's default ModelConfig: the one
annotated agent-platform.giantswarm.io/is-default-model-config: "true".
The chart declares no model, so the lab declares it the way an installation
does: agentlab platform applies the ModelConfig anthropic in kagent
after the install, annotated the default, on the lab's aiModel setting
(agentlab.yaml, default claude-sonnet-4-6, the BOM's own default) with
prompt caching on (anthropic.promptCaching: true, cacheTTL: "5m") and no
baseUrl, which the chart's LLM routing policy sets on admission. The lab
renders none of kagent.providers, kagent.defaultModelConfig and
kagent.modelConfigs, which the chart refuses from agent-platform
4.175.0-rc.22. On an older release the values carry the model: from
4.175.0-rc.15 the kagent.modelConfigs entry anthropic marked
default: true with kagent.defaultModelConfig.enabled: false, before it
kagent.providers and the kagent chart's default-model-config. On every
line the ModelConfig references the Secret kagent/kagent-anthropic (key
ANTHROPIC_API_KEY), and agentlab platform waits for the default to be
Accepted, carry the annotation and resolve its Secret.
The proofs never assume the model's name. One that is given no
--model-config asks agent-manager for the namespace's default
(list_model_configs, the entry with default: true) as the person it runs
as. agent-manager reports the default from 2.19, the chart's own range from
4.175.0-rc.15 on. An agent-manager that reports no default at
all (an older line) answers default-model-config.
The API key is a real
credential, so unlike the lab's throwaway passwords it never enters
agentlab.yaml or the rendered state/ files. The Secret exists after every
agentlab up and agentlab platform, so the ModelConfig resolves on a fresh
lab too (the run waits for ResolvedRefs), from the first of (the portal's
copy for Backstage's AI chat, agent-platform/agentlab-anthropic, by the same
rules; see Backstage):
- A recorded source (
aiKey.sourceinagentlab.yaml;agentlab configure --ai-key-source op://<vault>/<item>/<field>,<file>#<path>of a SOPS file, ork8s://<context>/<namespace>/<secret>/<key>): a reference, never a value.upandplatformread it — throughoporsops(on PATH;configurerefuses a source without its reader) or the embedded client — and write it into the lab's Secret within agentlab's process: the value never reaches an argument, a file or the output, the run prints its length. A recreated lab (down,up) carries the key again without a manual step; a Secret already holding a real key is left alone and the source not read (delete it and re-run to place the source again). A source that cannot be read — the reader missing or not signed in, the path reaching nothing — fails the run naming the Secret and the source: a lab whose configuration says where the key is never runs on a placeholder. See Secret sources. $ANTHROPIC_API_KEYon the host, when no source is recorded: the Secret is created from it in-process (left alone once it holds a real key; delete it and re-run to rotate).- A placeholder otherwise, as for an extra model without a
key: the ModelConfig resolves and agents start, but every turn on it fails
at Anthropic until the key is placed — the run says so, loudly, with the
three ways: the source recorded,
agentlab place-secret <ref> kagent/kagent-anthropic/ANTHROPIC_API_KEY(it replaces the placeholder; the next run leaves the real key alone), or the variable exported andagentlab platformre-run. Without any of those, run the agent proofs on a host model: Agent proofs without an Anthropic key.
The same key powers Backstage's AI chat (see
Backstage gotchas for its no-key behavior).
Further models — the host model servers through model-manager,
platform.extraModels — are their own ModelConfigs; see Models.
Without a key, the agent proofs run on a host model through --model-config:
see Agent proofs without an Anthropic key.
Two consumers of the lab resolve skills through GitHub's REST API: the
portal's skill discovery (GET /api/gs/agent-skills?repoUrl=…, the create
wizard's skills step) and agent-manager (list_skills, the commit
create_agent pins a branch to, refreshSkills). Without a token GitHub allows 60 requests an hour per egress
address, and the kind cluster shares this machine's — a handful of
backstage-test runs within an hour exhaust it, after which discovery comes
back truncated (the proof refuses that by name) until the window resets.
A token lifts that, from a recorded source (githubToken.source in
agentlab.yaml; agentlab configure --github-token-source op://<vault>/<item>/<field>, or <file>#<path> of a SOPS file): up and
platform read it and place it while the Secret lacks it, the value in
agentlab's process only (Secret sources), and a placement that
fails fails the run. The lab never takes $GITHUB_TOKEN either (only
self-update reads it): a token exported in its environment reaches no
consumer. Without a source discover names the Secret the lab lacks,
agentlab-github-token (key GITHUB_TOKEN) in agent-platform, and up and
platform warn on stderr, naming githubToken.source, unless the skills
GitHub App is recorded; agents-test then reports its refreshSkills step as
a SKIP with the same reason.
agentlab up/platform place the Secret agentlab-github-token (key GITHUB_TOKEN) in
agent-platform: the portal takes it through extraEnvVarsSecrets and the
lab's app-config overlay (integrations.github[].token: ${GITHUB_TOKEN}),
and agent-manager through the chart's skills.github.tokenSecret. Both
then call GitHub authenticated (5000 requests an hour; the rate-limit headers
say so). A copy in kagent that an earlier agentlab placed is removed. A fine-grained token with public read access is enough; a token that
reads a private skill repository lets agent-manager resolve skills from it.
The token travels vault -> agentlab's memory -> Secret and never enters
agentlab.yaml, state/ (the rendered values carry the Secret's name), a
log line or a process's argv. A placed token stays across runs; after a
rotation in the vault, agentlab place-secret <ref> agent-platform/agentlab-github-token/GITHUB_TOKEN (or deleting the Secret and
re-running) rotates the Secret.
A skills GitHub App is the way a lab reaches GitHub without any token: agent-manager's chart takes a read-only App (skills.github.app.secretName) and resolves skills with its installation tokens, at the App's rate limit. agentlab configure --github-app-id <id> --github-app-installation-id <id> --github-app-private-key-source op://<vault>/<item>/<field> records it as githubApp in agentlab.yaml (the ids are public; the key is a reference). A lab that already records the workspaces GitHub App (platform.workspaces.github, docs/workspaces.md) records only its installation, agentlab configure --github-app-installation-id <id>: agent-manager then resolves skills as that App, its id and private key source taken from the workspaces entry. With the workspaces App's OAuth client recorded too (clientId and clientSecretSource, or githubApp.clientId and githubApp.clientSecretSource for an App of its own), the portal's skill discovery calls GitHub as the same App: every up and platform write the Secret agentlab-portal-github-app (GITHUB_APP_ID and GITHUB_APP_CLIENT_ID applied, GITHUB_APP_PRIVATE_KEY and GITHUB_APP_CLIENT_SECRET placed from their sources), the portal's extraEnvVarsSecrets take it, and the overlay's integrations.github lists the App with publicAccess: true, so a public repository of any owner gets an installation token. Every up and platform apply the ids to the Secret agentlab-github-app in agent-platform and place the key from its source while the Secret lacks it (key private-key, the value in agentlab's process only, Secret sources; a failed placement fails the run), and the values name the Secret for agent-manager and, on a chart that runs the skill-manager (its values schema or defaults carry the skill-manager key, read from the chart itself, so a release, a branch build and a chart directory are judged alike), the skill-manager (skill-manager.github.app.secretName), which takes no token: without the App it reads public repositories anonymously. agent-manager's chart refuses the App together with tokenSecret, so githubApp and githubToken.source are not recorded together.
Without either the lab is as before: the values name no Secret, the
consumers call GitHub unauthenticated, and a Secret an earlier run created
stays — unreferenced — until agentlab down (a run that merely lacks the
export never deletes a credential; kubectl -n agent-platform delete secret agentlab-github-token does). backstage-test, agents-test and the
rehearsal print the window before their first skill-resolving step
(GitHub API window (unauthenticated: this machine's shared window): 12 of 60 requests remaining, resets 14:32:10 CEST) and, when it holds fewer requests
than the run spends (backstage-test: 30, its discovery and the create pin),
wait once until the reset instead of failing on a truncated listing. The
wait is skipped only when every consumer the run reads through carries a
credential: agent-manager for agents-test, agent-manager and the portal
for backstage-test.
backstage-test runs its refreshSkills steps (E4/E5) only when
agent-manager's Deployment carries a GitHub credential; without one it skips
them with a verdict naming the anonymous rate limit.
The migrate run reads no GitHub token. The connectivity chart's
agent-manager migrate run (the cut-over to the api.kagent.dev line)
resolves public skill repositories without a credential and reports a private
ref as pending; neither githubToken.source nor the skills GitHub App reaches
it. The chart ships it as the suspended CronJob
agent-platform-connectivity-agent-manager-migrate in kagent, never
scheduled. The post-install,post-upgrade hook
agent-platform-connectivity-agent-manager-migrate-start creates the run
agent-platform-connectivity-agent-manager-migrate-<hash> from it, once per
pod template: an upgrade that changes nothing in it starts no new run. The run
is owned by the CronJob, not the release, so its failure never fails the
agentlab platform upgrade; read it in its Job, its log and the ConfigMap
kagent/agent-manager-migrate-report. To run it again:
kubectl -n kagent create job agent-platform-connectivity-agent-manager-migrate-rerun-1 \
--from=cronjob/agent-platform-connectivity-agent-manager-migrateThe chart documents the run in agent-platform's
UPGRADE.md
("the migrate run is started by a hook from a suspended CronJob") and in
templates/kagent/migrate-cronjob.yaml;
its values (agentManager.migration.*) are in the connectivity chart's
README.
An agent whose HelmRelease a Flux Kustomization applies carries the
Kustomization's provenance labels (kustomize.toolkit.fluxcd.io/name and
/namespace); agent-manager reports it managed: gitops and refuses every
live write with gitops_owned, because the next reconciliation would undo
it. Such an agent is changed with a pull request: update_agent in
mode: commit rewrites the release's file in agent-manager's directory of the
owning repository and opens the pull request as the person. The portal's edit
page dry-runs every change with validate_agent (update: true) first and
offers the write only once the dry run is valid, so the dry run takes mode
too and answers as the write would: gitops_owned in mode apply, valid with
the composed manifests in mode commit.
agentlab agents-gitops-test is that edit, headless and as the person: the
platform's agent-manager composes a release, the proof applies it with the
Flux labels and reads it back managed: gitops; agent-manager answers the
change's dry run gitops_owned in mode apply (and unsupported in mode
commit while it offers no commit mode); update_agent is refused and the live
release stays as it was. The agent goes away at the end of the run. The pull
requests of mode commit are agentlab backstage-test's commit stage (below).
For a four-manager GitHub proof, set platform.managerGitHubProof: true in
the proof lab. This enables and pins agent-manager 3.0.0-rc.10,
cluster-manager 0.37.0-rc.1, model-manager 1.20.0-rc.10, skill-manager
0.2.0-rc.1 and muster 5.63.2. Model-manager uses its Kubernetes backend;
cert-manager and the KServe LLMInferenceService CRDs, controller and runtime
configs are enabled with it. No host model server is needed. Use a meta chart that
admits these releases and the skill catalog values.
All four managers use the workspace GitHub App's provider App github.
Each has separate broker credentials and may exchange only for that target.
Configure platform.workspaces.github.appId and clientId, and bind the
existing App's private key and OAuth client secret through the workspace
credential tooling. Enable platform.devctl to expose the pinned workspace
App as provider App github, or use the workspace providerApps mode.
Set githubApp.installationId to the App installation covering the proof
repositories; its private-key source comes from platform.workspaces.github.
These are references and public identifiers, never inline credentials.
An already bound Kubernetes Secret can be the source:
k8s://kind-agentlab/agent-platform/workspace-github/private-key.
The credential tooling requires the caller to hold that lab's lease.
Configure the workspace App's two proofRepositories and authorize its
installation for them. Its OAuth callback allowlist must include the proof
lab's muster /oauth/proxy/callback URL.
Run agentlab --lab agentlab platform --open=false --trust=false with the
proof binary after the binding is complete. A configured provider whose
credential binding is missing fails the install. The existing lab behavior
is retained when managerGitHubProof is false.
Before granting github, check read tools on all four managers and private
skill listings. Commit dry runs and private skill resolution must identify
the missing github grant and offer its sign-in link. Grant it once, repeat
the calls twice, and verify no additional prompt. Check delegated callers
are refused. Use only the configured proof repositories for PR creation;
do not merge proof PRs. An account already holding a grant does not prove
the first-grant behavior, and a credential binding alone does not prove consent.
The lab's agent-manager offers commit mode (get_info reports
capabilities.commit) while the platform runs agents, the workspaces'
github instance renders (platform.workspaces.github, its App's ids and
Secret in place), muster keeps that instance's App as the provider App
github (one provider App per instance, or the workspace-manager's pin with
platform.devctl on; the pin alone keeps none) and the agent-manager the install
resolves is 3.0.0-rc.10 or newer (components.agent-manager.versionRange in
platform.valuesFiles admits a release candidate). agentlab platform
prints which.
A commit opens its pull request as the person with their grant of the
github instance's App — the grant they made once for the workspace-manager
— the way an installation does it without pinning agent-manager's MCP
registration to an App (agent-manager's github.enabled with
github.tokenExchange):
- agent-manager presents the person's forwarded ID token to muster's RFC 8693
broker (
https://muster.<domain>/oauth/token, through the edge, under the lab CA) as the confidential clientagent-manager, whose secret the lab generates once (certs/agent-manager-commit/) and places as the Secretagent-platform/agent-manager-github-exchange, which also holds the client id agent-manager reads (client-id); - muster (
muster.oauth.server.tokenExchangeBroker, the lab Dex its trusted subject issuer) releases that person's own grant of the App (https://github.com/apps/<appId>) to that client and for that one audience,github, the provider App agent-manager's registration lists inauth.providerApps; a commit without the person's grant answersgrant_required, which muster turns into that App's sign-in link.
Apply mode, every read and every other proof keep the ID token: nothing else
needs the grant. The App is installed with contents and pull-request write on
the instance's proofRepositories; the first is the commit target of the
proof. agentlab backstage-test's commit stage (Backstage)
drives the portal's create, edit and delete as pull requests on it and closes
every one again.
platform.organizations (on by default; agentlab configure --organizations[=false]) renders the chart's
agentPlatformOrganizations.enabled: true with the LLM listener it needs
(llmRouting.enabled) and agentPlatformOrganizations.organizationCRD.enabled: true, because the lab has no KaaS to install the Organization CRD: the
meta chart installs that CRD and agent-platform-operator, and
the connectivity chart renders the organizations' roles
(agent-platform:organizations-admin, admin, editor, user) and their
admission policies, and selects the organization namespaces by the label
agent-platform.giantswarm.io/organization (Substrate's credential provider,
the workers' admission, kagent's authorizer). muster serves those
namespaces' MCPServers only once the chart sets its
mcpServerNamespaceSelector (MCP servers per tenant). It takes effect with the agents runtime on a
chart from agent-platform 4.175.0-rc.4 on (config.OrganizationsChartFloor), the default chart included;
below it, up says so and leaves the chart's earlier shape alone. The
tenants mode the chart removed (platform.tenants, agent-manager's tenant
reconciler) is gone from the lab: an agentlab.yaml that still names it
loads, and the key is not written back.
Each organization is an Organization (security.giantswarm.io/v1alpha1,
cluster-scoped) with spec.capabilities.agentPlatform.enabled: true, the
shape agreed on giantswarm/organization-operator#673. The operator
reconciles it into one organization namespace, agents-<name>, and reports
the name in the entry of status.namespaces with capability: agentPlatform; the lab reads that entry and never computes the name.
status.conditions holds the operator's conditions: AgentPlatformReady,
AgentPlatformOrphaned (reasons InInventory, MissingFromGit,
DeleteMerged), and, while a deleted organization is erased,
AgentPlatformErasing, whose reason names the cleanup step. No
organization-operator runs in the lab, so status.namespace and the kaas
entry of status.namespaces (its org-<name>) stay empty. The
organization's admins are spec.admins (kind User or Group, and
name): the operator binds them to agent-platform:admin in the namespace
(RoleBinding organization-admins), and the chart's admission policy
refuses every other writer of a binding to that role, the lab's admin too.
The lab writes no admin binding.
The default organization. agentlab up (and agentlab platform) keeps
the Organization default (display name Lab, the annotation
agent-platform.giantswarm.io/display-name), with the platform Harness, one
worker (spec.capabilities.agentPlatform.workers.replicas) and the group
platform-admins in spec.admins, and waits until the operator reports it
AgentPlatformReady. Then it writes the editors, organization-editors to
agent-platform:editor for the group developers, and the organization's
model: the ModelConfig anthropic on
the lab's model, marked default, its key in the tenant credential
tenant-credential-anthropic, placed the way the lab places the Anthropic
key everywhere (anthropic.go: the recorded source, the host environment,
else the placeholder; the value never reaches an argument, a file or the
output). The chart's admission
policy fills in the LLM listener as its baseUrl. Last, the first developer
creates an agent's HelmRelease there as a server-side dry run with their own
Dex token, which RBAC and every admission policy of the namespace (the
HelmRelease field lock among them) judge; up fails if it is refused. The
summary names the namespace. The lab's values also count the operator's
ServiceAccount quota under count/serviceaccounts (HACKS.md U42).
The lab runs organizations on the Organization kind from these releases
of giantswarm/giantswarm#39492 on:
| Component | First release | Pull request |
|---|---|---|
agent-platform (the chart: the Organization CRD, roles and admission policies) |
4.187.0-rc.5 | giantswarm/agent-platform#1489 |
| agent-platform-operator | 0.5.0-rc.1 | giantswarm/agent-platform-operator#69 |
| agent-manager | 4.0.0-rc.1 | giantswarm/agent-manager#475 |
| the portal (Backstage) | 3.52.0-rc.3 | giantswarm/backstage#3651 |
Earlier releases reconcile AgentPlatformOrganization. To run it:
-
The chart at 4.187.0-rc.5 or newer:
agentlab configure --chart-version 4.187.0-rc.11. -
The component releases. The chart's ranges admit the operator's, agent-manager's and the portal's first releases on the kind while they are release candidates only with
gitops.prereleases. Aplatform.valuesFilesoverlay turns it on:# prereleases.yaml, listed in platform.valuesFiles gitops: prereleases: true
agent-manager takes every organization by its name: each tool of an organization's contents takes one argument
organization, the name of theOrganization, and never its namespace (see The tools take the organization's name). -
agentlab platform, thenagentlab organizations-test.
The lab checks the first two steps and stops at once when one is missing:
- A chart without the
OrganizationCRD switch. With organizations on,agentlab upandagentlab platformread the values schema of the chart they install. When it has noagentPlatformOrganizations.organizationCRD, they stop before the install, in place of Helm's schema error, and name this section, the chart floor andagentlab configure --organizations=false. A chart that cannot be read, or that has no schema, is left to the install. - A CRD of the earlier shape. Before the default organization,
upandplatformread the servedOrganizationCRD. When the schema ofv1alpha1names the fields ofspecandspec.capabilities.agentPlatformis not among them (the chart's earlier builds havespec.agentPlatform), the run stops and names the chart floor of step 1. A schema that does not name the fields ofspecis left to the run. Every part oforganizations-testreads it at its start too. - An operator or agent-manager without the
Organizationkind, or of the earlier shape. Before the default organization,upandplatformask the API server whether the ServiceAccounts of the Deploymentsagent-platform-operatorandagent-managermay listorganizations.security.giantswarm.io(aSelfSubjectAccessReviewas each), and read their images' tags: a release (a release candidate too) before the component's first release in the table reconcilesAgentPlatformOrganization. A tag that is no semantic version (a local build) and a dev build are left to the run. Every part oforganizations-testasks the same at its start. When a component may not read the Organizations or is a release before its floor, the run stops and names the component, its image and the overlay of step 2, in place of an organization that is notAgentPlatformReadyafter three minutes.
organizations-test --part admins also proves that nobody switches an
organization's Agent Platform off: the chart's policy
agent-platform-organization-switch-off refuses the update (decision D10;
see The admins part).
From giantswarm/agent-manager#475 at 31a58c6 (giantswarm/giantswarm#39503),
agent-manager finds an organization's namespace itself, in the
agentPlatform entry of its Organization's status.namespaces (from
6f0d54a; before it, in status.agentPlatform.namespace):
- The member tools (
list_organization_members,add_organization_member,remove_organization_member),list_organization_connectors,set_organization_connectorandset_organization_egress_policytakeorganization(required) in place ofnamespace; a call that still passesnamespaceis refused. set_organization_model,replace_organization_credentialanddelete_organization_objecttakeorganization(optional): without it they act on the installation's own models, for a cluster admin.- The agent and session tools take
organizationfor an organization's agents,organizationwithclusterfor an agent on a workload cluster, andnamespaceonly for the installation's own platform namespaces (kagent, andpublic-agentswhere the chart has it;agentlab turnpasses the namespace of the Agent it starts, so it cannot start an organization's agent). An organization's namespace asnamespaceis refused asinvalid_request, naming the organization to pass to a caller with a right in it;organizationwithnamespaceand noclusteris refused asinvalid_request. - An organization that does not exist and one the caller has no right in
are answered alike:
not_found: organization <name> not found. - Every answer about an organization's object carries
organization.
The lab's own proofs on kagent pass namespace: kagent or nothing, as
before. organizations-test passes the organization's name to every tool it
calls (the members' start_session included), and judges each answer's
organization where the answer carries it. Its Slack surface needs
klaus-gateway 4.18.10 or later, the first release with
giantswarm/klaus-gateway#616 (a part of giantswarm/giantswarm#39503): that
gateway starts a thread's Session on an organization's agent with
start_session and the organization's name. An older gateway passes the
agent's namespace, which this agent-manager build refuses, so its Slack turn
(step S3) fails. Without --gateway-image or --gateway-binary the proof
takes the version that the klaus-gateway component's HelmRelease applied, or,
with no such HelmRelease, the newest release that the agent-platform chart's
range admits. A lab whose component runs a version before 4.18.10 needs the
component updated or --gateway-image with 4.18.10 or later.
The gateway names an organization's tenant on a roster row and in a refusal
by the organization's name. It reads that name from the label
agent-platform.giantswarm.io/organization on the organization's namespace,
through the Kubernetes API, for a member and for a stranger alike. A gateway
that cannot read the API server writes namespace <namespace> instead. So
the proof gives its gateway the lab's kubeconfig in each shape: the binary
and the image on the host network get the lab kubeconfig as it is, and the
image on the kind network (macOS) gets a copy that names the API server as
the control-plane node's port 6443. It is the lab's admin kubeconfig, more
than the gateway's ServiceAccount has on an installation (HACKS.md U52). The
gateway does not wait for its first list of the namespaces before it
serves, so a roster asked right at its start can also name the namespace.
A lab that ran the earlier AgentPlatformOrganization model has no
migration: start the Organization kind on a new lab (agentlab down, then agentlab up).
agentlab organizations-test (tenants-test is an alias) is the proof
(#1149, the agent-platform-organizations plan). It keeps
two organizations, agentlab-a and agentlab-b, each an Organization
with platform-admins in spec.admins, and binds one member to each as an editor by the group in their token
(RoleBinding agentlab-members, subject oidc:tenant-a or
oidc:tenant-b): alice@lab.local and bob@lab.local, which agentlab configure --organizations adds (The member users).
A member who is also in platform-admins, viewers or developers is
refused: each reaches agents outside their organization. Each organization
gets the lab's model.
Each member creates the agent agentlab-organizations in their own
organization as themselves: a HelmRelease of the agent chart written through
the Kubernetes API with their Dex token, which the chart's HelmRelease field
lock admits (the operator's chart source and Helm ServiceAccount). The agent
becomes Ready on the organization's copy of the platform Harness, and a
turn as its member answers, the credential provider reading credentials for
the namespace's atespace from that namespace only. Then:
- The same answer on every surface. The agents each member sees through
the Kubernetes API (a list in every organization namespace as the
member), through the kagent API at the edge (
ListAgents) and in Slack (klaus-gateway's per-caller roster, giantswarm/klaus-gateway#354) are one set: their own organization's agent, nothing of the other's. The platform tenant's agents inkagentare not judged (they go with giantswarm/agent-manager#166). The Dev Portal surface is a page, proven in a browser by the portal's own suite (giantswarm/backstagee2e/agentlab/organizations.spec.ts), not by this proof. - The negative cross-organization tests. Each is a verdict that names
its surface and the boundary it proves, and each has a twin in the
member's own organization that is admitted, so a refusal for another
reason fails it:
- Kubernetes API (RBAC): the first member's lists of agents, agent
templates, RemoteMCPServers, muster MCPServers, HelmReleases,
ModelConfigs and Secrets in the other organization answer 403 (their own
are answered; an editor reads no Secret anywhere); their create of an
agent there answers 403, in their own it is admitted (dry runs); a
SelfSubjectAccessReview for
list sessions.api.kagent.devthere is denied (its twin:list agents.api.kagent.devin their own is allowed); - kagent API and A2A (kagent's authorizer):
CreateSessionand a first A2A message on the other organization's agent arePermissionDenied, no Session of it is made and no credential read for its atespace; an Agent's create, change and delete there arePermissionDenied, while the same in their own organization pass;ListSessionswithall_creatorsisPermissionDeniedfor both members and answered for the admin; - Slack: each roster is the member's own organization's, its row naming
the organization by its name; a pick of the other organization's agent
is refused with nothing reaching it, and a turn in a thread on it is
refused, each refusal naming that organization by its name
(
(<organization>)). The gateway reads the names from the organization namespaces' labels through the API server; a row or a refusal that namesnamespace <namespace>fails with a hint that the gateway has no access to the API server; - muster: with an
MCPServerin each organization namespace, each member lists muster's namespace's servers and their own organization's; with their RoleBinding gone a moment, their own goes too; the first member'score_service_startandcore_auth_loginnaming the other organization's server read word for word as for a server that does not exist; - agent-manager through muster (its tools take the organization's name):
the first member's
create_agentwith their organization's namespace asnamespaceand noorganizationis refused asinvalid_requestnaming their organization; theircreate_agentnaming the other organization reads word for word as for an organization that does not exist (not_found); theircreate_agentwith their organization and its namespace and noclusteris refused asinvalid_request. None writes a HelmRelease. The twin of each: theirget_agentof their own agent by their organization's name is answered with that organization and its namespace; - models and the llm listener: the first member's agent naming the other organization's ModelConfig is refused at admission or fails on that reference, and no credential of the other organization is read for its atespace, so the other's key never travels through the listener for it; the same agent on their own model is admitted;
- egress gateway: the first member's agent (declaring
https://example.com) probes that origin, the API server and Substrate's API on 443 from its actor; judged from the gateway's record, the declared origin is forwarded (the twin) and each in-cluster request is refused by the gate for the actor's egress policy, or held before any connection opened: the probe's own line shows no HTTP status and a name resolution or connection failure. An HTTP answer from the endpoint, a TLS or certificate failure, or an ambiguous failure fails the check.
- Kubernetes API (RBAC): the first member's lists of agents, agent
templates, RemoteMCPServers, muster MCPServers, HelmReleases,
ModelConfigs and Secrets in the other organization answer 403 (their own
are answered; an editor reads no Secret anywhere); their create of an
agent there answers 403, in their own it is admitted (dry runs); a
SelfSubjectAccessReview for
- The management-cluster profile. The operator's ResourceQuota
agent-platform-organization-objectsadmits ServiceAccounts up to its hardcount/serviceaccountsand refuses the next; with a Kyverno PolicyException inpolicy-exceptionsthat lifts every rule foragents-*, a WorkerPool patch and delete, a worker-labelled pod and an exec into a worker are still refused by the chart's ValidatingAdmissionPolicies (as the admin, cluster-admin); the credential provider's live grants (/statusz) give each organization's atespace its own namespace only. Secret access per component (giantswarm/agent-platform#1269), each read made with the ServiceAccount's own token (TokenRequest, no client certificate) against a dummy workload cluster kubeconfigorg-lab/agentlab-kubeconfig: ate-controller getsate-system/egress-mitm-ca-pooland is refused everything else; both credential providers get the model key inkagentand in an organization namespace and are refused the kubeconfig, the pool and a list; the connectivity install hooks, whose identity exists only during a hook event, get it from the release's own hook manifests for the check (removed afterwards) and read the pool only. A get the authorizer allows may answer NotFound; a refusal must be 403. The cleanup check starts a member-owned READY session, records its organization in a suspended installation Kustomization's settled inventory, then removes that inventory entry and waits for the operator to reportAgentPlatformOrphaned=Truewith the reasonMissingFromGit. First the refusal, a verdict of its own: the lab admin's delete withkustomize.toolkit.fluxcd.io/prune: enabledmust be refused by the chart's ValidatingAdmissionPolicyagent-platform-organization-delete-intent, and the organization, its namespace and the session must still be there; the prune marker alone does not erase an organization whose file is gone from git. Then the path of a merged delete pull request: the check setsagent-platform.giantswarm.io/delete-pull-requeston the organization (a URL-shaped value that names no real pull request, as agent-manager writes it in mode commit), waits forAgentPlatformOrphaned=Truewith the reasonDeleteMerged, and deletes. That deletion must remove the organization, namespace, actors and snapshot prefix, and refuse another resume of the session. A seeded control object under the second organization's UID must survive that cleanup. The check requires kagent 1.31.1-rc.3 or newer and an operator that supports the configured path-style store; it preserves the five-minute snapshot cleanup delay.
organizations-test --part credentials proves an organization's keys are
typed only into agent-manager's credential API, never into a tool call
(agent-manager docs/organization-credentials.md). It keeps its own
organization, the Organization agentlab-credentials (a previous
run's is erased first), with platform-admins and the other admin in
spec.admins, and acts as
the first admin. The key it types is a random value made in the process and
printed only as its SHA-256. Where a verdict says nothing is written, there
is no ModelConfig of the model, and no tenant-credential-* Secret of it
at all, not even an empty one or one with another key; only where that
Secret existed before the refused write does a Secret without a value at
apiKey pass. Each verdict:
set_organization_modelthrough muster (x_agent-manager_set_organization_model, withorganization: agentlab-credentials, as every model, connector and egress call of the part, whose answers must name that organization back) for a new model without a key writes nothing: no ModelConfig, notenant-credential-*value, and the answer names a pending credential operation. In commit mode no open pull request of the person touches the organization's content path yet.- The same call from three MCP client generations, each on mcp-go's client:
a 2026-07-28 client declaring URL elicitation gets
input_required, its message prefixed[agent-manager]by muster (giantswarm/muster#1812), and retried withrequestStatehaving accepted (consent to open the page, not the page's outcome) getsinput_requiredagain for the same operation; a 2025-11-25 client that declared it at initialize gets-32042carrying one elicitation of modeurlwith anelicitationIdand the form's URL; a client without it gets a result whosecredentials[].nextcarries the link. Every link must be anhttpsURL, agent-manager'scredentials.uiURLtemplate expanded (RFC 6570) with the operation, the organization and the namespace only, so no value or token travels in it. That client also getsstructuredContentwith aresource_linkonceset_organization_modeldeclares anoutputSchemathrough muster'sdescribe_tool(giantswarm/agent-manager#329; skipped while it declares none), thestructuredContentvalidated against that schema. - On the 2026-07-28 client, for a model of its own each, the person declines
the URL elicitation and dismisses it (
decline,cancel): each retry ends the call with an error result sayingdeclinedorcancelled, the operation readscancelledand nothing of that model is written. - The form's save, the way the portal's form posts it
(giantswarm/backstage#3364):
GET /api/v1/credential-operations/{operation}with the person's token answers the confirmation with a strongETagandCache-Control: no-store. Another lab user, in neitherplatform-adminsnorviewers(the defaultdev@lab.local) and bound by name as an admin of the organization too, prepares an operation of their own (modelagentlab-credentials-other): each reads their own, each read of the other's is refused with the status of an operation that does not exist (404 or 403, no oracle), and an anonymous read answers 401; the reads of the admin's operation are one verdict, that user's own operation another. That user then cancels their operation:DELETEwith a staleIf-Matchanswers 412, with itsETag204; it readscancelled, a save of it answers 412 and nothing of that model is written. An agent-manager older than 2.24.0-rc.2 refuses that user's own operation withforbidden: credential state cannot be verified(it reads the credential Secret as the caller, whichagent-platform:adminmay not): there the verdicts on their own operation and its cancel are aSKIPnaming giantswarm/agent-manager#360; from 2.24.0-rc.2 on they run, and that refusal fails them. - A viewer: a third lab user, in
viewersonly (the defaultviewer@lab.local; never the other admin, never inplatform-adminsordevelopers), bound by name to the organization's read-only roleagent-platform:user. A lab without three such people fails the part naming the user it lacks. Before any verdict, access reviews with each person's own token must show the viewer listing the organization's ModelConfigs and creating neither Secrets nor ModelConfigs, and the other admin creating both; else the part fails as a wrong fixture. The viewer'sset_organization_modelfor a model of their own must be refused with the apiserver's RBAC denial of that user creating the Secret or the ModelConfig in the organization's namespace (agent-manager 2.24.0-rc.2 and newer, whose dry-run create of the Secret as the caller meets it), with nothing written; an older agent-manager refuses every person outsideplatform-adminson reading the Secret first, which is aSKIPnaming giantswarm/agent-manager#360, and any other refusal fails. A second verdict: theirPOSTof the admin's pending operation, with its currentETagand a value, answers what an unknown operation answers (404 or 403), nothing is written and the admin's operation stays pending at thatETag. - A Secret another consumer comes to reference: the admin prepares model
agentlab-credentials-sharednamingtenant-credential-agentlab-credentials-shared, then a ModelConfig applied by the lab references that Secret too; the save answers 409conflictwith nothing written, and preparing the model again (a freshrequestId) is refusedconflictfor that reference. It runs after the save, like the next verdict, so the admin's operation is saved well within its 15 minutes. - The confirmations of
set_organization_connectorandset_organization_egress_policy, each without its credential: each shows its one write and lists only that object as the Secret's consumer (keytoken), the connector with the URL it sends the value to, the egress policy with exactly the two origins that get the credential and not the one reached without it. Both are cancelled, nothing written. - A save after lost rights (#1250): the other admin,
whose access review allows creating Secrets and ModelConfigs in the
organization, prepares model
agentlab-credentials-lostand reads its confirmation andETag. The lab then removes them from the organization'sspec.admins, waits until agent-platform-operator'sorganization-adminsRoleBinding follows, and their access review must deny both creates within 15 seconds; else the verdict fails as a wrong fixture. TheirPOSTof the value with thatETagmust answer 403forbidden(not 404, another person's; not 412, a staleETag; not 409, an expired operation), theirGETof the operation 403 naming the denied create of that model's ModelConfig or Secret in the organization's namespace andagent-platform:admin, and nothing is written. agent-manager checks the person's rights again on each read, save and cancel, before it writes or changes the operation. A second verdict binds them again: the operation readspendingat the sameETag, and the save with it writes the Secret (its SHA-256 compared) and the ModelConfig. Both run after the save, so the admin's operation is not kept waiting. The binding is given back in the cleanup too, so a failed run leaves the organization usable. While they are removed, an interrupt (Ctrl-C) or SIGTERM binds them again before the signal ends the program; the program waits at most 35 seconds for that write (a write in flight, then its own), then ends without it, and the next run creates the organization again. An interrupt at any other moment ends the run at once, as before. Below agent-manager 2.24.0-rc.2 both are aSKIPnaming giantswarm/agent-manager#360: that user cannot prepare an operation of their own, and the first admin, a platform admin, cannot lose the right. - Back on the admin's operation, its confirmation lists only the ModelConfig
(key
apiKey); aPOSTwithoutIf-Match(428 from agent-manager 2.23.0, giantswarm/agent-manager#354; 400 also admitted, and said, on an older one) and one with a stale tag (412) write nothing and leave it pending;POSTwithIf-Matchand only the requested Secret/key returns the receipt, a secondPOSTwith the sameETaganswers the same receipt, and the original call retried on the 2025-11-25 client returns it too (the same pull request on the same branch), the Secret's and the ModelConfig's resourceVersions unchanged. agent-manager binds an operation to the person, the client and the MCP session it sees, so the 2026-07-28 client's retry returns that receipt too when muster reached agent-manager on one session for both, and otherwise staysinput_requiredfor its own operation. Neither the receipt nor a retry's answer carries the value. The lab's portal reaches agent-manager through muster only, so the part calls the agent-manager Service's REST listener on a port-forward, the hop a portal backend takes. Without commit mode the save writes the Secret live, its SHA-256 is compared and the ModelConfig exists. In commit mode the receipt's pull request is the only open one on its branch. - In commit mode, the receipt's pull request is read back with your
ghlogin: opened by the person, its commit authored by them, the ModelConfig file<contentPrefix>/<name>/modelconfig-<model>.yamland the Secret file<contentPrefix>/<name>/<secret>-secret.enc.yamlin it, the Secret SOPS-encrypted, and no file carrying the value. Before the merge the cluster holds no value of the Secret and no ModelConfig, so the Flux verdict is Flux's. - Flux: the person merges the pull request, and the organization's own
Kustomization, which agent-platform-operator keeps in commit mode
(
--flux-namespace,--flux-source-name) withdecryption.provider: sopsand--flux-decryption-secret, applies and decrypts it: the Secret's SHA-256 matches and the ModelConfig exists. Where the repository's base requires a merge queue, the part waits until the queue has merged the pull request (ten minutes at most) before Flux's own wait starts. The age identity is the lab's, generated once intocerts/organization-credentials-sops/(a key file its group or others can reach is refused) and placed as that Secret (an existing Secret the lab did not write is left alone). The repository's.sops.yamlmust encrypt the content path for its recipient; the part prints the rule to commit when it does not. After a merge, the run removes the organization's content path from the base branch with your git credentials; a failed run after the merge keeps it, since Flux would prune the retained organization, and prints the commands that remove it by hand. A pull request nothing merged is closed and its branch deleted. - Neither agent-manager's nor muster's logs since the run began carry the value, plain or base64; a component of which no line was read fails the verdict, since an empty read proves nothing.
- Both 2025-11-25 clients listen on their standalone stream from the start:
a
notifications/elicitation/completemay only reach the client that initiated the elicitation, carrying itselicitationId, and the client without URL elicitation receives none. A server may send no completion at all (muster from giantswarm/muster#1812 relays none, giantswarm/muster#1830), which the verdict reports. - A sign-in a server of the organization's namespace needs: an OAuth
MCPServerthere, modelled onlab-oauth-fixturewithout a pinned client, readsAuth Required, andcore_auth_loginfor<namespace>/<name>is a URL elicitation whose message names that key, either in muster's own sentence (Sign in to <namespace>/<name> to continue) or as the[<namespace>/<name>]prefix muster puts on a backend's elicitation. delete_organizationerases the organization (itsconfirmis the organization's name): withoutconfirmit says what goes, the model and its credential Secret named among it once they are live (saved in apply mode, or applied by Flux: it lists the cluster's objects, never a pull request's), the confirmed dry run deletes nothing, the confirmed call deletes it; the namespace goes, in commit mode so do the operator's Kustomization and ServiceAccount named after it in the Flux namespace, and no RoleBinding anywhere refers to it.
What the part stands on is read from the live lab and never configured
by it, except the SOPS age Secret the organizations' Kustomizations decrypt
with: the lab places its own only where none exists or agentlab wrote it.
Each missing piece is a SKIP naming its fix: agent-manager's
credentials.uiURL (its --credential-ui-url), muster speaking MCP
2026-07-28, commit mode (github.tokenExchange, tenants.commit.repository)
and the person's grant of the workspaces' github App, a Ready
kustomize-controller (flux-engine.instance.components), and
agent-platform-operator's commit-mode flags. muster's
mcpServerNamespaceSelector must select the organization namespace for the
sign-in verdict, and its OAuth server must accept a redirect URI on a private
address (oauth.server.allowPrivateIPRedirectURIs, which the lab sets with
platform.klausGateway, HACKS.md U43): in the lab muster's own host resolves to
the edge's cluster IP, and the tenant server signs in to muster itself. From
agent-platform 4.190.0-rc.2 muster calls the tenant server, its first 401
included, and its issuer through its outbound guard, which refuses both
unless muster.outbound.privateHosts lists their hosts: the Service
muster.agent-platform.svc.cluster.local and muster's public host
muster.<platform.domain>. The lab lists both with platform.organizations
(HACKS.md U53), and the sign-in verdict fails, naming the fix, while muster's
configuration does not (agentlab platform renders them and rolls muster).
organizations-test --part admins proves that an organization's admins
exist only in its Organization's spec.admins (#1225,
giantswarm/giantswarm#39501). agent-platform-operator binds them to
agent-platform:admin in the organization namespace (RoleBinding
organization-admins), the chart's admission policy refuses every other
writer of a binding to that role, and agent-manager's member tools refuse
the admin role. The right to create an Organization is one RBAC rule on
the kind, which the lab's admin holds. It needs the releases of The
Organization kind.
The lab's admin creates two organizations through create_organization:
agentlab-admins-a, whose admin is the group of alice@lab.local, and
agentlab-admins-b, whose admin is bob@lab.local by name. The first lab
user outside platform-admins (dev@lab.local by default) is the
outsider. The verdicts:
- nobody of alice, bob and the outsider may create RoleBindings, bind
agent-platform:adminor createOrganizations cluster-wide; - for each organization,
create_organizationthrough muster in mode apply answers created with the admins inspec.admins, writes no RoleBinding, the organization becomes Ready, and the operator'sorganization-adminsbinds those admins alone toagent-platform:admin; - a RoleBinding to
agent-platform:adminin alice's organization is refused by an admission policy as alice (its admin) and as the lab's admin (cluster-admin), while alice's binding toagent-platform:editoris admitted (dry runs); - alice's
add_organization_member(organization: agentlab-admins-a) with the roleadminis refused andorganization-adminsdoes not change, while the roleuser(a dry run) is admitted and answers for that organization; - alice, who may not create
Organizations, is refusedcreate_organization, and no organization of that name exists afterwards; - the lab's admin (
cluster-admin) sends an update that setsspec.capabilities.agentPlatform.enabledofagentlab-admins-a(AgentPlatformReady) to false: the chart's ValidatingAdmissionPolicyagent-platform-organization-switch-offrefuses it, while an update ofspec.capabilities.agentPlatform.workers.replicasthat keeps the switch on is admitted (dry runs; decision D10 of giantswarm/giantswarm#39492). A chart without the policy fails the check, which then names the policy and giantswarm/agent-platform#1489; update_organizationreplaces the admin group ofagentlab-admins-awith alice by name:organization-adminsfollows;update_organizationempties the admins ofagentlab-admins-b:organization-adminsgoes and the organization stays Ready.
A successful run deletes both organizations. A failed run keeps them for diagnosis, and the next run deletes them first.
organizations-test --part public proves that an organization shares
agents and MCP servers with every person on the installation through its
public namespace (giantswarm/giantswarm#39646, the organization-sharing
plan). agent-platform-operator keeps it beside the organization namespace
from its 0.7 line, reports it in
status.capabilities.agentPlatform.publicNamespace and binds the
installation's "everyone" (tenants.platform.users, system:authenticated
by default) there to agent-platform:platform-user (RoleBinding
agent-platform:everyone). agent-manager's tools reach it with public: true
from 4.2.0-rc.3. The part refuses, by name and version, an
agent-platform-operator before 0.7.0-rc.1 or an agent-manager before
4.2.0-rc.3: agent-platform runs the operator's 0.7 line from 4.190.0-rc.8
(agentlab configure --chart-version), and a platform.valuesFiles overlay
admits the agent-manager release candidate (gitops.prereleases, or
components.agent-manager.versionRange). A dev build or a local build is
left to the run.
The part keeps the proof's organizations and members: alice is a member of
agentlab-a and no member of agentlab-b, bob an editor of agentlab-b.
agentlab-b's admin (the lab's admin, by platform-admins in spec.admins)
publishes in its public namespace: the organization's model, the agent
agentlab-organizations-public through create_agent with public: true,
and the MCP server agentlab-public-mcp, which is also in agentlab-b's
organization namespace. The server is agentlab's fake pro (a fixed board) in a
container on the kind network, answering without a bearer: muster gives a
server outside its own namespace no identity. muster calls an organization's
server through its outbound guard, which refuses a Service of the cluster over
plain http unless muster.outbound.privateHosts lists the host: the lab lists
the fixture's Service there with platform.organizations on agent-platform
4.190.0-rc.2 or later (HACKS.md U53), and the part refuses to start, naming
the fix, while muster's configuration does not list it (agentlab platform
renders it and rolls muster). The container runs the agentlab
binary, which must be a static Linux executable: on macOS build one
(GOOS=linux CGO_ENABLED=0 go build -o agentlab-linux .) and pass it with
--mcp-fixture-binary. The verdicts:
- each organization has its organization namespace and its public namespace,
both labelled with the organization's name and UID, and only the public one
with
agent-platform.giantswarm.io/space: public; the public one has the operator'sagent-platform:everyone, toagent-platform:platform-userwith at least one subject, and access reviews as alice allow listing agents and creating sessions inagentlab-b's public namespace and deny listing agents in its organization namespace; - bob, an editor of
agentlab-b, cannot publish: his agent's create in its public namespace answers 403, while his create in its organization namespace and the admin's create in the public namespace are admitted (dry runs); hiscreate_agentwithorganization: agentlab-bandpublic: trueis refused with nothing written, while the admin's is admitted (dry runs); - alice's
list_agentswithpublic: truelistsagentlab-b's public agent withorganization: agentlab-bandpublic: true, and names its public namespace underpublicNamespaces; - the same listing names
agentlab-a's public namespace nowhere: alice may list agents there, and it holds no agent and no musterMCPServer;agentlab-b's is named; - alice's
start_sessionof the public agent withoutpublicreads word for word as for an organization that does not exist (not_found); withorganization: agentlab-bandpublic: trueit answerspublic: trueand a Session on the public agent that alice created, Ready; - a turn of that Session answers (kagent API);
- muster lists alice
agentlab-b's public server and not the same server of its organization namespace, which bob lists; - alice's agent
agentlab-organizations-public-toolsinagentlab-a, whose toolset isserver:<agentlab-b's public namespace>/agentlab-public-mcp: under that toolset (X-Muster-Toolset, the header the agent's runtime sends) alice's catalogue holds the server'slist_issues, its call reaches the fixture, and muster logs its dispatch of that tool under alice's subject (the call's own record, found by its tool, so a kind VM clock ahead of the host's does not drop it); under the toolset that names the server ofagentlab-b's organization namespace the call is refused for alice and answered for bob; - a turn on alice's agent calls the public server: the fixture records the
call, and in the turn's own window (after her
start_session, before herdelete_session) muster accepts her credential and logs the turn's calls under her subject. The window ends ten seconds after the turn by the host's clock, for muster's stamps from a kind VM clock that runs ahead; the part deletes the Session only after it reads muster's log; - where agent-manager runs the organizations in mode commit (as for The
credentials part) into one of
platform.workspaces.github.proofRepositories, the part's only repository to write in, two verdicts in this order:- while
agentlab-b's content path (<content prefix>/agentlab-b) has no kustomization file there, the admin'screate_agentwithpublic: truein mode commit is refused (conflict), as agent-manager refuses it, with no pull request and nothing live. The part then adds the content path'skustomization.yamlthrough a pull request that it opens and merges with this host'sghlogin, as the credentials part merges its own. It lists what Flux's generated kustomization took in: the path's YAML files and those of its plain subdirectories at any depth, a subdirectory as a whole only where it has a kustomization file of its own (Kustomize refuses a resource directory without one), and neverpublic. Where the proof repository's base requires a merge queue, the part merges without deleting the branch, waits until the queue has merged the pull request (ten minutes at most), then deletes the branch. The proof's organizations are applied live, so their content path has no kustomization file until the part adds it. The file starts with a marker comment, and the next run removes it the same way before it proves the refusal again. A kustomization file the part did not write is left as it is: the refusal is then aSKIP, and the next verdict uses that file; - with the content path's kustomization file, the same write opens a pull
request whose files are all under
<content path>/public, and that kustomization file on its branch does not listpublic. Nothing is live, and the part closes that pull request;
- while
- where the lab runs klaus-gateway (
platform.klausGateway), or the run names one with--gateway-imageor--gateway-binary, and it is 4.21.0-rc.3 or later (refused by name below it): alice's Slack roster names the public agent's tenantagentlab-b · Public, and her pick of it from the roster answers in a Session she created on it, through the host gateway of the proof's Slack surface. Without klaus-gateway the verdict is aSKIPthat says so; - the move (agent-manager's
move_agent, giantswarm/agent-manager#531, from 4.2.0-rc.9; where muster lists nox_agent-manager_move_agentto the admin, whatever agent-manager's image tag says, a digest or a local build included, the three verdicts are aSKIPthat names that release): the admin creates the private agentagentlab-organizations-movedinagentlab-b, and the admin and bob each start a Session on it. The move's dry run (to: public) names the admin's own Session and counts bob's, or states that other people's Sessions go too where kagent does not let the admin count them. The move writes the agent in the public namespace and deletes it from the organization namespace, and alice starts a Session on it withorganizationandpublic: true; - the admin moves it back (
to: private), and alice cannot start a Session on it. Once its HelmRelease and Agent are gone from the public namespace, her start withpublic: truemust be refused, with whatever code, and she must hold no live Session of it, as she lists her own. kagent still knows a deleted Agent for a while and answersconflict: ... Agent does not have a ready prepared revision(for at least two minutes in the live runs) where agent-manager would answernot_found; the verdict names the code it saw. Withoutpublicher start reads word for word as for an organization that does not exist; - bob's move of the agent is refused by the API server (
forbidden, naming him, at whatever step: agent-manager's read of the target as him, as in the live run, or its dry run), with nothing written or deleted: read right after the call, before the part's cleanup, its HelmRelease is the same object, not being deleted, and the public namespace holds none.
The turns and the Slack start need the model's key: on the lab's placeholder
key they are a SKIP that says so. --skip-slack leaves Slack out. Every run
removes what the part wrote in both namespaces of each organization (the
public agent, the server, the moved agent, the public namespace's model,
alice's agent), also the full proof, so a failed public part leaves nothing
for the proof's rosters and listings to find.
organizations-test --part cleanup runs the orphan cleanup check alone, creating the proof agents and a member-owned session directly through kagent without a model turn. The default run includes this check after all other organization checks. The former --part erasure spelling remains an alias. See the operator's glossary for the distinction between organization deletion and cleanup.
The report prints one PASS or SKIP line per verdict, [surface] boundary — what was seen; a failure stops the run as FAIL [surface] boundary: .... --skip-slack leaves klaus-gateway out (its lines read
SKIP); --gateway-image and --gateway-binary pick the gateway as for
klaus-gateway-test (on macOS the image runs on the kind network, HACKS.md
U35). On macOS a --gateway-binary is refused before the proof starts
unless the lab CA is in the system trust store (agentlab trust): the
gateway calls muster, and a Go program on macOS verifies against the system
trust store, not the SSL_CERT_FILE the lab gives it. Use --gateway-image
there. Successful runs delete both proof organizations and remove the installation inventory fixture and its temporary operator setting. Failed cleanup retains the organizations, the session, the fixture Kustomization agentlab-organizations-inventory and the operator's setting for diagnosis and reports the failing step. The next run (the full proof or --part cleanup) removes them first and says so: the proof organizations that carry the proof's ownership label (one AgentPlatformOrphaned with MissingFromGit through the same delete pull request annotation), the fixture Kustomization with its Role and RoleBinding, and the operator's flag. It refuses, naming the object, one of those names without the proof's ownership label. Other failures remove the transient agents, Sessions, PolicyException and quota ServiceAccounts.
After the erase, the reads through kagent and Substrate that prove the end state (GetSession and ResumeSession on the member's session, ListActors in the organization's namespace) try a transport error (gRPC Unavailable: the kagent controller restarting, a reset connection) again, with a note that names the read and its error. The session's reads try for up to three minutes; ListActors within the one minute the actors have to go. Every other answer is judged at once, and a transport error past the bound fails the check with that error and the bound.
The proof leaves out muster's per-organization sign-in: a server of an
organization namespace that signs in needs muster to read its client Secret
there, and the organizations' subject policy refuses a RoleBinding of
muster's ServiceAccount, which lives in another namespace; and its callback
(/oauth/ns/<namespace>/callback) names a namespace the operator generates,
which the lab Dex's static redirect URIs cannot list ahead.
The kagent UI is host-published like the other components:
http://localhost:8081 (platform.agentsPort in agentlab.yaml);
agentlab open agents opens it. Being plain HTTP on loopback, it involves the
lab CA in nothing — no trust question, no browser warning. The UI does
no OAuth in this lab, so it needs none of the issuer tricks — the kagent-ui
Service is simply type: NodePort, pinned to node port 30880 by the kagent
component's postRenderers patch (the chart's Service template renders no
nodePort field — HACKS.md U9), and the kind config maps that onto the host. Like every
kind port mapping it is fixed at node-creation time, so a cluster created
before this mapping existed needs agentlab down && agentlab up; the stopgap
there is the old port-forward:
kubectl -n kagent port-forward svc/kagent-ui 8081:8080The topology is the installation's (the 4.x line, kagent API v2): the
controller serves gRPC only (kagent.api.v1alpha1 for the control plane,
lf.a2a.v1 for the turns) as a GRPCRoute on the edge with the chart's JWT
Strict policy in front — every bearer verified against the lab Dex,
x-user-id set from the verified email claim — and the controller runs the
fleet's auth.mode: trusted-proxy, re-deriving the caller from the same
bearer; agentlab platform-test asserts both (a call without a token refused
at the edge; a forged header attributed to the token's subject), and the
proofs' turns take that path as the person (internal/lab/kagentapi.go).
Every agent is an AgentTemplate paired by its Agent with the platform
Harness kagent (spec.harnessRef) and runs as an actor
on Agent Substrate — the WorkerPool kagent-default's gVisor workers in the
kagent namespace, the control plane in ate-system — which the chart ships
and the lab installs nothing of; kagent's kagent_v2 database lives on the
platform's CNPG Cluster kagent-pg next to Substrate's (see Agent Substrate
and the platform
Postgres).
The agent chart 1.x renders one RemoteMCPServer per agent pointing it at
muster with its toolset header. Sessions started through agent-manager are
bound to the person in muster; the egress gateway authenticates MCP calls
with the actor's JWT in place of the runtime's placeholder. Lab deviations
on the kagent side, same spirit as the deviations
table:
the JWKS source is the lab Dex, the snapshot store the bundled RustFS, the
ServiceMonitor / OTel exporters are off (the line serves no /metrics, no
OTLP gateway in kind). A git skill of an AgentTemplate is fetched during
the golden boot, which Substrate's egress gate has to let through;
agentlab skills-test is that proof, see The skills
proof.
An agent that never becomes Ready names what Substrate's egress gateway
refused in the verdict of every proof that waits for it: each distinct
refusal (status, method, destination, the gateway's reason), and, when the
gateway answered from a failed call to the control plane (actor egress policy …, actor identity check …, credential provider …) rather than
from the destination, the endpoints of the control plane's Service
ate-system/api that are no pod of Deployment ate-api-server. A pod in
ate-system that carries the api-server's selector labels and serves
nothing takes a share of those calls and refuses them; the git fetch of the
golden boot then reads as a 403 from github.com.
The controller serves gRPC only (kagent.api.v1alpha1 for the control
plane, lf.a2a.v1 for the turns) behind the connectivity chart's
GRPCRoute kagent-controller on the edge — native gRPC over HTTP/2, the
services matched by name — with the AgentgatewayPolicy
kagent-controller-jwt validating the person's Dex id_token (JWT Strict)
and rewriting x-user-id from the token's email claim for the controller's
trusted-proxy authenticator; whatever x-user-id a caller sent is
replaced. Swarmgeist (klaus-gateway) and the Dev Portal's backend speak to
the controller this way, and so do the proofs' turns
(internal/lab/kagentapi.go): one gRPC connection on the lab's TLS
transport (agentgateway.<domain>:<gateway port>, the lab CA trusted), the
a2a-go/v2 client on its gRPC transport for the turns and the stubs
generated from kagent's protos (internal/kagent/gen, see
development.md) for the rest. Every call carries
authorization: Bearer <id_token>; every A2A call names the Agent as its
tenant (<namespace>/<name>) and the Session that holds the conversation
through the message's context id (the Session's id; started for the person
through agent-manager's start_session over muster, idempotent on
requestId, and deleted afterwards through its delete_session),
and carries the human-in-the-loop extension request (A2A-Extensions: https://kagent.dev/extensions/hitl/v1), so a tool bound with
requireApproval pauses the task at input-required with a decidable
tool_approval_request instead of a plain notice. The answer is consumed
as a stream (SendStreamingMessage: the submitted task, working, the
artifacts, the terminal status). start_session binds the Session's actor
to the person in muster, so the runtime's MCP calls carry the actor's JWT
and muster serves them as the person, never the platform. A Session
created straight at the controller (CreateSession) is not bound: the
platform Harness forwards no caller token, so its runtime reaches muster
with no credential.
agentlab a2a-test is the proof of that path, with the assertions the
surfaces rely on: the route and its policy exist and are Accepted; a call
without a token is refused at the edge (Unauthenticated — on a raw
HTTP/2 POST the gRPC frame gets the trailers-only grpc-status 16, a plain
POST gets 401); a forged x-user-id beside a valid token is replaced
(GetCurrentUser names the token's person); ListAgents lists the proof's
Agent Ready on the platform Harness with the display-name and icon-url
annotations as Swarmgeist reads them; start_session is idempotent; a turn
streams its answer; on the proof's agent — the Generic
chart with toolset: [preset:read-only] and muster.requireApproval: true
(chart ≥ 1.1.0) — a tool call pauses the task, the person's approval
resumes it to completed with muster logging the call under the person, a
rejection ends it without the call (every request is decided until the task
settles, within five minutes: how many tool calls the model needs is its
own; a request asked again after its decision fails the step, the decision
did not resume the task); CancelTask on a running turn ends it
server-side (GetTask reports it canceled) and the session takes a
following turn. It leaves nothing behind: the sessions over gRPC
(ListSessions lists none of its), the agent's release and render on
the cluster.
fixtures/agents/codex-coder/ is one coding agent's definition, the same on
the lab and on an installation: a codex agent on a ChatGPT subscription
login whose Sessions work in a workspace of giantswarm repositories. It is
the inputs of the platform's own tools, applied through muster as the person,
nothing applied by hand:
| File | What |
|---|---|
model-config.yaml |
Its model, a ModelConfig object: openai-chatgpt-codex in kagent (openAI.credentialType: chatgptOAuth, openAI.apiFormat: responses, the login Secret kagent-chatgpt-login). An installation declares it next to its agents; on the lab the platform.extraModels entry chatgpt-login with credentialType: chatgptOAuth is the same model, whose ModelConfig agentlab renders itself (Extra model configs) |
agent.json |
agent-manager's create_agent input: codex-coder on the Harness codex and that ModelConfig, the toolset preset:read-only, a system message for branch-per-change work in /workspace |
workspace.json |
workspace-manager's create_workspace input: the workspace giantswarm, one source on the provider instance github, owner giantswarm, the public repositories by name. organization and the provider instance are the lab's (lab, github); an installation sets its own, and adds the private repositories it is meant to see with update_workspace |
The agent carries no repository and no workspace: a workspace is chosen when
a Session starts. Read and write access is the person's own, through the
workspace's provider: the person grants the provider instance's GitHub App
once in muster, authorize_workspace checks that the person reads every
repository and signs the grant, start_session takes it, and the egress
gateway sets the person's App token on the provider's git and API hosts per
request (Workspaces). The sandbox holds no
token; git push and gh pr create work as the person, and only where the
App is installed and the person may write.
What it needs where it runs:
- The codex Harness:
platform.codingwithcodexamongplatform.coding.harnesseson the lab;kagent.harnesseson an installation (The coding agents proof). - The login Secret
kagent/kagent-chatgpt-login(access_token,refresh_token,account_id, labelledkagent.dev/chatgpt-login: "true"): onecodex login --device-authof its own per lab or installation, since the refresh token rotates on every use and two refreshers on one login spend each other's. On the lab the three keys are placed from that login'sauth.jsonwith the operator's secret tooling, never read by a session, and the Secret labelled; on an installation it is a SOPS Secret (agent-platformdocs/chatgpt-login.md). - The workspaces with a GitHub provider instance whose App is installed on
giantswarmwith Contents, Pull requests and Issues read and write (The provider instance github), and the Session admission.
The order, as the person through muster (agentlab login --audience agent-platform gives a lab user the token for it):
x_workspace-manager_create_workspacewithworkspace.json, thenx_workspace-manager_get_workspace giantswarmuntillastSync.resultisSucceeded.x_agent-manager_create_agentwithagent.json, thenx_agent-manager_get_agent_status codex-coderuntil it is Ready.x_workspace-manager_authorize_workspace giantswarm:grantedwith agrant, orconnect_requiredwith muster's sign-in for the App.x_agent-manager_start_session codex-coderwithworkspaceGrantand the first message;x_agent-manager_get_sessionreads the answer.
go test ./fixtures/... checks the definition against what the tools refuse
at write time and the model it names against the values entry.
agents-test compares agent-manager's ServiceAccount permissions with an
unbound ServiceAccount and the grants required by the platform values.
With agentPlatformOrganizations.enabled and agent-manager's --multi-tenant
flag, it requires exactly get and list on namespaces for organization
discovery, and allows get and list on organizations.security.giantswarm.io beside
it: agent-manager 2.24.0 and later render that row in the same ClusterRole
(agent-manager-namespaces) for list_organizations, which answers only the
organizations the caller's access reviews allow; an earlier release renders
the namespaces row alone. Kubernetes RBAC cannot restrict a list by label or
by caller; agent-manager filters for organization labels and performs
organization operations as the caller. Namespace or organization writes,
watches, name-scoped variants and reads of Secrets are not part of that grant
and fail the proof. With organizations disabled, neither discovery row is
allowed. Older charts using
tenants.organizations.enabled retain their separate reconciler checks.