Repository navigation
feat(edge): agent edge subcommand — single-identity north-south ingress control plane - #236
Merged
Merged
Conversation
…ss control plane Add `agent edge`, a subtractive control-plane mode for an edge (north-south ingress) proxy that dials mesh pods directly over mTLS — no node proxy/DaemonSet in the path. The transport migration (#98-#101) already made node egress a plain per-source mTLS HTTP/2 client to pod_ip:15008, so the edge is the same path with a single identity instead of many; the node data plane is unchanged. - `runEdge`: controller-runtime manager hosting only the xDS server + registry refresher (no CNI server, no per-pod storage, no SPIRE bridge). Shared identity/registrar/SPIRE flags extracted into registerSharedFlags so the node path is untouched. - Envoy fetches its single SVID + trust bundle straight from SPIRE over a static spire_agent gRPC SDS cluster (config.SDSConfigSourceFromCluster + proxy.EdgeUpstreamTransportSocket), not the agent's ADS stream. SAN pinning is preserved (inline matchers over the SDS bundle). - Edge data plane: BuildEdgeListener (0.0.0.0:8080, RDS, readiness filter ahead of the router), BuildEdgeRouteConfiguration (exposed vhosts + 404 catch-all, no ODCDS), and NewServiceCluster gains a perDownstreamConnectionPool flag so the single-identity edge multiplexes upstream connections. - Snapshot cache edge mode: SetEdgeMode/SetEdgeIdentity/SetStaticDependencies; the static dependency set scopes the registrar watch to exactly the exposed services. Exposure is seeded from --expose for now; an EdgeRoute CRD watch replaces it in a follow-up. Unit tests cover the edge transport socket, listener, route config, SDS config source, static dependency seam, and edge-mode listener composition. Co-Authored-By: Claude Opus 4.8 <[email protected]> Claude-Session: https://claude.ai/code/session_01Pihqn5RmVPhV9HTdBnqbvY
bpalermo
added a commit
that referenced
this pull request
Jun 19, 2026
…eRoutes Add the edge-proxy proposal doc reflecting what shipped across #236–#239 (single-identity agent edge control plane, Envoy-talks-SPIRE-SDS-directly, the EdgeRoute CRD, the edge.enabled chart, downstream TLS), resolving the docs/proposals/003_edge-proxy.md references already in the code/chart comments. Also adds test/e2e/edge: a manual talos-main runbook (enable the edge, expose a service, drive traffic, assert direct-to-pod + edge identity in XFCC + hitless rollout + live route changes) and example EdgeRoute manifests (host-based and multi-port). Co-Authored-By: Claude Opus 4.8 <[email protected]> Claude-Session: https://claude.ai/code/session_01Pihqn5RmVPhV9HTdBnqbvY
bpalermo
added a commit
that referenced
this pull request
Jun 19, 2026
…eRoutes Add the edge-proxy proposal doc reflecting what shipped across #236–#239 (single-identity agent edge control plane, Envoy-talks-SPIRE-SDS-directly, the EdgeRoute CRD, the edge.enabled chart, downstream TLS), resolving the docs/proposals/003_edge-proxy.md references already in the code/chart comments. Also adds test/e2e/edge: a manual talos-main runbook (enable the edge, expose a service, drive traffic, assert direct-to-pod + edge identity in XFCC + hitless rollout + live route changes) and example EdgeRoute manifests (host-based and multi-port). Co-Authored-By: Claude Opus 4.8 <[email protected]> Claude-Session: https://claude.ai/code/session_01Pihqn5RmVPhV9HTdBnqbvY
bpalermo
added a commit
that referenced
this pull request
Jun 19, 2026
…eRoutes (#240) * docs(edge): proposal 003 (as-built) + talos e2e runbook + example EdgeRoutes Add the edge-proxy proposal doc reflecting what shipped across #236–#239 (single-identity agent edge control plane, Envoy-talks-SPIRE-SDS-directly, the EdgeRoute CRD, the edge.enabled chart, downstream TLS), resolving the docs/proposals/003_edge-proxy.md references already in the code/chart comments. Also adds test/e2e/edge: a manual talos-main runbook (enable the edge, expose a service, drive traffic, assert direct-to-pod + edge identity in XFCC + hitless rollout + live route changes) and example EdgeRoute manifests (host-based and multi-port). Co-Authored-By: Claude Opus 4.8 <[email protected]> Claude-Session: https://claude.ai/code/session_01Pihqn5RmVPhV9HTdBnqbvY * docs(edge): correct exposure wording — external host only, no mesh FQDN, no --expose Align the proposal doc and e2e assets with the routing fix (#241): the edge routes ONLY by explicit external host; the internal mesh FQDN is not an edge entrypoint and `hosts` is required. Drop the removed `--expose` seed from the doc, runbook, and example. Co-Authored-By: Claude Opus 4.8 <[email protected]> Claude-Session: https://claude.ai/code/session_01Pihqn5RmVPhV9HTdBnqbvY --------- Co-authored-by: Claude Opus 4.8 <[email protected]>
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.
What
PR1 of the edge proxy (north-south ingress) plan: an
agent edgesubcommand that runs a single-identity ingress control plane dialing mesh pods directly over mTLS — no node proxy / DaemonSet in the path.The transport migration (#98–#101) already made node-proxy egress a plain per-source mTLS HTTP/2 client to
pod_ip:15008, with each destination pod's own netns-bound inbound listener terminating mTLS and recording the caller in XFCC. The edge is the same path with one identity instead of many, so the node data plane is unchanged — inbound listeners already accept any trust-domain peer.Highlights
runEdge— subtractive variant ofrunAgent: controller-runtime manager hosting only the xDS server + registry refresher. No CNI server, no per-pod storage logic, no SPIRE bridge. Shared identity/registrar/SPIRE flags extracted intoregisterSharedFlagsso the node path is untouched (node-only flags like--spire-admin-socket/--mounted-registry-dirstay offedge).spire_agentgRPC SDS cluster (config.SDSConfigSourceFromCluster+proxy.EdgeUpstreamTransportSocket), not the agent's ADS stream. The agent runs no SPIRE bridge in edge mode. SAN pinning (feat(proxy): pin upstream peer identity to the service's SPIFFE IDs #165/feat(proxy): multi-key subset selection #166) is preserved —match_typed_subject_alt_namesis inline, only the bundle comes over SDS.proxy.BuildEdgeListener(0.0.0.0:8080, RDS, readinesshealth_checkfilter ahead of the router),proxy.BuildEdgeRouteConfiguration(exposed vhosts + 404 catch-all, no ODCDS catch-all), andNewServiceClustergains aperDownstreamConnectionPoolflag so the single-identity edge fully multiplexes upstream connections.SetEdgeMode/SetEdgeIdentity/SetStaticDependencies, with edge branches inListeners(),clustersEndpointsAndVhosts, andgenerateSnapshot. The static dependency set scopes the registrar watch to exactly the exposed services.--exposefor now; a follow-up PR swaps in anEdgeRouteCRD watch.Tests
Unit tests cover the edge transport socket (SDS source =
spire_agent, SAN pinning), edge listener, edge route config, the SDS config-source helper, the static dependency seam, and edge-mode listener composition. All existingNewServiceClustercallers updated to preserve node behavior (true).bazel build //...,bazel test //agent/... //registry/... --test_arg=-test.short(17/17), and--config=lintall pass.Follow-ups (per the approved plan)
EdgeRouteCRD (config.aether.io/v1) + live watch → replaces--expose, drives external-host vhosts.edge.enabledincharts/aether; bootstrap defining thespire_agentSDS cluster).🤖 Generated with Claude Code