Listener
A Skupper listener is the local endpoint that clients connect to when they want to consume a service exposed from another site. The listener is matched to one or more remote connectors by routing key, and Skupper routers forward matching client connections across the application network.
Outcome
A working listener gives local clients a host and port for a remote service.
local client -> listener host:port -> Skupper router -> matching routing key -> remote connector -> workloadKey ideas
- A site can have zero or more listeners.
- Each listener has a local connection endpoint, defined by host and port.
- Each listener has a routing key.
- A service is usable when at least one listener and one connector share the same routing key.
- On Kubernetes, a listener is implemented as a Kubernetes Service.
- On Docker, Podman, and Linux, a listener is a listening socket bound to a local network interface.
- Listener-side routing policy lets one listener endpoint select among multiple routing keys.
Common fields
The Listener resource uses these core fields:
spec.routingKey: the identifier that matches this listener to connector resources, usually in remote sites.spec.host: the hostname or IP address local clients use for the listener endpoint.spec.port: the port local clients use for the listener endpoint.
If a service needs multiple ports, create multiple listeners using the same host value and different ports.
Creation paths
See also:
- Creating a listener using YAML (Kubernetes)
- Creating a listener-side routing policy using YAML
- Creating a listener using YAML (local systems)
- Creating a listener using CLI (local systems)
- Skupper Ansible resource module
For Kubernetes-style YAML workflows, create a Listener resource and apply it through Skupper:
apiVersion: skupper.io/v2alpha1
kind: Listener
metadata:
name: backend
namespace: west
spec:
routingKey: backend
host: east-backend
port: 8080skupper system apply -f <filename>For Ansible workflows, pass the same Listener resource YAML to skupper.v2.resource. On Kubernetes, the module applies the resource to the target namespace:
- name: Create backend listener on west
skupper.v2.resource:
platform: kubernetes
namespace: west
kubeconfig: "{{ kubeconfig }}"
def: |
apiVersion: skupper.io/v2alpha1
kind: Listener
metadata:
name: backend
spec:
routingKey: backend
host: east-backend
port: 8080On local system platforms, the same module writes the resource into the local Skupper namespace definition. Reload or start the system site after the resource is present:
- name: Define backend listener on west
skupper.v2.resource:
platform: podman
namespace: west
def: |
apiVersion: skupper.io/v2alpha1
kind: Listener
metadata:
name: backend
spec:
routingKey: backend
host: east-backend
port: 8080
- name: Reload west system site
skupper.v2.system:
platform: podman
namespace: west
action: reloadFor local CLI workflows on Docker, Podman, or Linux platforms, create a listener directly:
skupper listener create <name> <port> --routing-key <routing-key>
skupper system reloadWhen --routing-key and --host are not specified, the listener name is used as the default routing key and host.
Verify
Check listener status:
skupper listener statusExpected shape:
NAME STATUS ROUTING-KEY HOST PORT MATCHING-CONNECTOR MESSAGE
backend Ready backend ... 8080 true OKThe service is not operational until the listener has a matching connector. In resource status, the relevant signals are hasMatchingConnector and the conditions Configured, Matched, and Ready.
Listener-side routing policy
A standard listener binds one local endpoint to one routing key. Listener-side routing policy extends that model: one local endpoint can select among multiple routing keys and use a strategy to decide how traffic is distributed.
Current Skupper source material configures listener-side routing policy with the MultiKeyListener resource. For this wiki, treat that resource name as the current API shape rather than a separate concept family. This distinction matters because policy-based listener behavior may become the default listener behavior in the future.
Observability
The Network Observer API exposes runtime state for listeners:
GET /api/v2alpha1/listeners— List all listeners across the networkGET /api/v2alpha1/listeners/{id}— Get a single listener by identity
Each listener record includes the routing key, site, router, and endpoint details. Use the API to verify that listeners are configured and to check cross-site matching status.
For detailed API schema information, see the Network Observer API Reference.
Caveats
- A listener does not expose a workload by itself; a connector with the same routing key is required.
- A routing key can match multiple listeners and multiple connectors.
- Listener-side routing policy aggregates several routing keys behind one local endpoint. In current YAML, this is configured with
MultiKeyListener. - On local-system platforms, configuration changes may require
skupper system reload.