Repository navigation
feat(agents): egressPolicyRefs and list_egress_policies - #242
Merged
Merged
Conversation
…fs, list them with list_egress_policies
Published Helm chart
|
| Chart | agent-manager |
| Version | 2.11.1-r7812d4fet20261022123817hfe0a372 |
| OCI reference | oci://gsoci.azurecr.io/charts/giantswarm/agent-manager:2.11.1-r7812d4fet20261022123817hfe0a372 |
| Digest | sha256:f87275081d2d91dd27878dc32bea52d7b9fb64f905d5c38dd3549c3604ba9136 |
| Registry | public — gsoci.azurecr.io |
| Git catalog | giantswarm-test-catalog (index) |
Pull this chart
helm pull oci://gsoci.azurecr.io/charts/giantswarm/agent-manager --version 2.11.1-r7812d4fet20261022123817hfe0a372Posted by architect-orb · build 5264 · commit fe0a372 · updated in place on every push
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
An agent can select kagent's namespaced
EgressPolicyobjects throughAgent.spec.egressPolicyRefs, and the agent chart 2.3.0 rendersagent.egressPolicyRefsinto it (giantswarm/agent#104), but agent-manager'screate_agent,update_agent,validate_agentandget_agenttake and return onlyegressorigins, so neither the portal nor an MCP caller can pick a policy (giantswarm/giantswarm#38744).Proposed solution
egressPolicyRefs(a list of names) oncreate_agent,update_agent(replaces the list,[]clears it) andvalidate_agent, and the REST API; written toagent.egressPolicyRefs;get_agentreturns them from the Agent'sspec.egressPolicyRefs(the values while nothing is rendered).list_egress_policies(GET /api/v1/egresspolicies): a namespace's EgressPolicies as the caller, each origin with its credential header's name; never the Secret.get_inforeports the capabilityegressPolicies.egresspolicies.Acceptance criteria
spec.egressPolicyRefs; unknown names, a namespace without policies and a coding Harness are refused;list_egress_policiesreports origins and header names and no Secret; REST route.platform.devImages, the agent chart 2.3.1 from the registry), as Organization-namespace users, neither a platform admin: inorg-eg38744,dev@lab.localboundagent-platform:editor, thetenant-agroup (alice@lab.local)agent-platform:user.list_egress_policieslistsexample(https://example.com) andiana(https://www.iana.org,credentialHeader: X-Api-Key), no Secret name.validate_agentandcreate_agentwithegressPolicyRefs: [example, npm]refused:EgressPolicy "npm" does not exist in namespace org-eg38744; valid: example, iana; with[example]valid (schema 2.3.1) and created; the rendered Agent carriesspec.egressPolicyRefs: [{name: example}], nospec.egress, and is Ready.update_agentto[example, iana](changedagent.egressPolicyRefs, rendered as both refs), to[nope]refused;get_agentreturns both.iananames a Secret that does not exist, andget_agent_statusreportsfailed … EgressPolicy "org-eg38744/iana": Secret "tenant-credential-iana" not found.kagent, an agent created through agent-manager with a ref to a policy holdinghttps://example.com: from its bash tool,https://example.comanswers 200 andhttps://www.wikipedia.organswers 403actor egress policy denied. Oncehttps://www.wikipedia.orgis added to the policy (the Agent's generation stays 1), a new Session reaches it with 200.validate_agenton theclaudeHarness with a ref refused:egressPolicyRefs eg38744-example: an agent on coding Harness claude reaches its Harness's origins only ….platform-testwas run.