Skip to content

Prove edge attachments as gateway backends #1507

Description

@privateip

Summary

The public listener design relies on the gateway delivering internet traffic to a provider's attachment and sending replies from the public address. Nobody has tested that path, and the gateway's delivery to a backend on its own node is unqualified.

This proof wires the path by hand on the containerlab gvpc lab before any API work starts.

Acceptance criteria

  • A client reaches a socket inside a provider pod through a gateway public address, over UDP and TCP, for IPv6 and IPv4.
  • Replies reach the client with the public address as their source.
  • Delivery to a backend on the gateway's own node either works, or its failure is documented and covered by the design.

Dependencies

Blocked by #1506.

Activity

  1. self-assigned this
    on Nov 28, 2026
  2. added theissue type on Nov 28, 2026
  3. privateip commented on Nov 28, 2026

    @privateip
    ContributorAuthor

    Implementation detail from the design.

    Deliverable

    A lab procedure and test that hand-wire one listener backend: an ingress gVPC, a SocketAccess attachment with a socket bound to its pod VRF, a /128 advertisement with VRFID and End.DT46 in the ingress VRF, veth registration in ifindex_vrf_table, and a gateway-namespace NetworkService and ServiceVIPBinding pointing at the attachment address. The gateway selects only tenant VPCAttachment backends today, so the selection is wired by hand too.

    Work items

    • Script the hand-wired backend in the lab without changing controller code, or behind a test-only switch.
    • Exercise UDP and TCP through an IPv6 VIP and an IPv4 VIP.
    • Repeat with the backend on a gateway node and on a node that is not a gateway.
    • Record results, including any failure in local delivery, in the design.
  4. privateip commented on Nov 28, 2026

    @privateip
    ContributorAuthor

    Triage: valid, and nothing on main does this yet.

    Checked against main at e7885de and the design branch of #1513 at 0001766. This is source inspection only; the lab has not run yet.

    • The gateway selects backends only from VPCAttachments (rulebackends.go). It resolves a backend's uSID from any BGPAdvertisement that carries a VRFID and a function. A stand-in VPCAttachment plus a hand-written /128 advertisement should therefore select an edge socket without a controller change.
    • usid_egress rewrites the reply source for any link in ifindex_vrf_table, whatever the link kind, and RegisterHostLink already registers edge host links. So the reply path should work as it is.
    • Local delivery probably fails. The gateway looks up the backend uSID with a direct FIB lookup, and on its own node that hits the locator's discard route, so the packet is dropped.
    • In the containerlab lab, every node that runs Galactic Edge also runs a gateway. "A backend on a node that is not a gateway" therefore becomes "a backend whose node is not the gateway the traffic arrives on", which the proof gets by pinning the VIP to the other gateway.

    Starting now, alongside the design review in #1506.

  5. privateip commented on Nov 28, 2026

    @privateip
    ContributorAuthor

    Plan for the Phase 0 proof:

    1. The reference provider (examples/edge-provider) gains a TCP echo next to its UDP echo. It binds to the pod VRF the same way, so it needs no privilege.
    2. A new TestListenerBackend in tests/edgeconformance, run with task verify:edge-listener, hand-wires one listener backend in the lab:
      • a dedicated ingress VPC;
      • an EdgeService granting SocketAccess, and one reference provider instance;
      • a stand-in gateway-namespace VPCAttachment for the attachment address;
      • a /128 BGPAdvertisement with VRFID and End.DT46;
      • one gateway-namespace NetworkService each for UDP and TCP, on a VIP of each family.
    3. From the off-fabric host it sends UDP and TCP to the IPv6 and IPv4 VIPs. It checks that replies come from the VIP and that the backend sees an IPv4 client under 64:ff9b::/96.
      • Remote delivery, with the VIP pinned to the gateway that does not hold the backend, must pass.
      • Local delivery, with the VIP pinned to the backend's own gateway, is recorded as it is, with the gateway's drop counters.
    4. The results go into docs/designs/edge-public-listener.md as a dated Phase 0 section. The PR is stacked on docs: Propose a Galactic Edge public listener #1513.

    Only test, example and documentation code changes. The test removes everything it creates.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

Fields

Priority

Low

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions