Kong Mesh on Universal

Uses: Kong Mesh

Universal mode runs Kong Mesh anywhere that isn’t a Kubernetes cluster: virtual machines, ECS tasks, bare metal, or a mix.

Universal mode is used for two purposes:

  • Deploying a global control plane: Kubernetes-native global control planes aren’t supported. A global control plane runs environment: universal against a non-Kubernetes store, even when the process itself is deployed on Kubernetes.
  • Managing workloads that aren’t on Kubernetes: A VM fleet or an ECS service joins the mesh through a Universal data plane proxy, and policies target it the same way they target a Pod.

Differences from Kubernetes

On Kubernetes the control plane watches the API server and derives most of the mesh from what is already there. A Pod becomes a Dataplane and a Service becomes a MeshService. Ports and protocols come from the Service definition. The injector adds the sidecar, wires transparent proxying, and hands the proxy a token.

On Universal there is no API server to watch, so you have to declare those inputs.

Concern

On Kubernetes

On Universal

Registering a proxy The injector adds the sidecar to a Pod and the control plane creates the Dataplane. You run kuma-dp and supply the Dataplane resource, either applied ahead of time or passed inline with --dataplane-file.
Which ports a workload exposes Read from the Service and the Pod’s container ports. You declare networking.inbound[] with a port, and a servicePort and serviceAddress where they differ.
The protocol of a port Derived from the Service port’s appProtocol. You set networking.inbound[].protocol. If unset, it defaults to TCP and the port silently loses every L7 policy.
Which destinations a proxy can reach The control plane generates outbounds. You declare networking.outbound[] with a backendRef, or, with transparent proxying, list destinations in networking.transparentProxying.reachableBackends. With neither, the proxy reaches nothing unless the control plane sets KUMA_DEFAULTS_RESTRICT_OUTBOUND=false.
Labels that policies select on Taken from Pod labels. You set them under the Dataplane’s top-level labels.
The MeshService for a workload Generated from each Service, and read-only. Generated by the control plane from the kuma.io/workload label. For more information, see Control plane automation.
Proxy authentication The proxy uses its Pod’s ServiceAccount token. You issue a dataplane token and pass it with --dataplane-token-file. Once a MeshIdentity issues workload-based identities, the token must be bound to the proxy’s kuma.io/workload value (--workload).
Transparent proxying The injector configures it. You install the iptables rules with kumactl install transparent-proxy (as root), then run kuma-dp as the user the rules exclude, with --transparent-proxy.
Readiness Taken from the Pod’s readiness probe. You configure a service probe, or report health from outside.
Workload identity SPIFFE path defaults to /ns/{namespace}/sa/{service-account}. SPIFFE path defaults to /workload/{workload}, which comes from the kuma.io/workload label.

Control plane automation

A Universal zone control plane running against a non-Kubernetes store generates:

  • MeshService resources, one per distinct kuma.io/workload label value, with a port per inbound. It re-checks every 2 seconds by default (KUMA_MESH_SERVICE_GENERATION_INTERVAL), and removes a MeshService an hour after its last proxy disappears (KUMA_MESH_SERVICE_DELETION_GRACE_PERIOD). A Dataplane without that label generates nothing, and the workload has no MeshService for policies or routes to target. Set KUMA_MESH_SERVICE_GENERATION_INTERVAL to 0 to turn generation off and manage MeshService resources by hand.
  • Workload resources, on the same basis.
  • Virtual IPs and hostnames, allocated from the IPAM ranges (241.0.0.0/8 for MeshService, 242.0.0.0/8 for MeshExternalService), so a Universal workload reaches a destination by name rather than by address.

Zone proxies

A regular Dataplane that declares networking.listeners of type ZoneIngress or ZoneEgress serves cross-zone traffic. Those proxies authenticate the same way as any other: with a dataplane token.

Help us make these docs great!

Kong Developer docs are open source. If you find these useful and want to make them better, contribute today!