Connector resource¶
A connector binds a local workload to listeners in remote sites. Listeners and connectors are matched by routing key.
On Kubernetes, a Connector resource has a selector and port for specifying workload pods.
On Docker, Podman, and Linux, a Connector resource has a host and port for specifying a local server. Optionally, Kubernetes can also use a host and port.
Examples¶
A connector in site East for the Hello World backend service:
apiVersion: skupper.io/v2alpha1
kind: Connector
metadata:
name: backend
namespace: hello-world-east
spec:
routingKey: backend
selector: app=backend
port: 8080
Metadata properties¶
name
string
required
The name of the resource.
| See also | Kubernetes object names |
|---|
namespace
string
The namespace of the resource.
| See also | Platform concept, Kubernetes namespaces |
|---|
Spec properties¶
routingKey
string
required
The identifier used to route traffic from listeners to
connectors. To expose a local workload to a remote site, the
remote listener and the local connector must have matching
routing keys.
| Updatable | True |
|---|---|
| See also | Routing key concept |
port
integer
required
The port on the target server to connect to.
| Updatable | True |
|---|
selector
string
frequently used
A Kubernetes label selector for specifying target server pods. It
uses `=` syntax.
On Kubernetes, either `selector` or `host` is required.
| Updatable | True |
|---|---|
| See also | Kubernetes label selectors |
host
string
frequently used
The hostname or IP address of the server. This is an
alternative to `selector` for specifying the target server.
On Kubernetes, either `selector` or `host` is required.
On Docker, Podman, or Linux, `host` is required.
| Updatable | True |
|---|
includeNotReadyPods
boolean
advanced
If true, include server pods in the `NotReady` state.
| Default | False |
|---|
exposePodsByName
boolean
advanced
If true, expose each pod as an individual service.
| Default | False |
|---|
tlsCredentials
string
advanced
The name of a bundle of TLS certificates used for secure
router-to-server communication. The bundle contains the trusted
server certificate (usually a CA). It optionally includes a
client certificate and key for mutual TLS.
On Kubernetes, the value is the name of a Secret in the current
namespace. On Docker, Podman, and Linux, the value is the name of
a directory under `input/certs/` in the current namespace.
| See also | Kubernetes TLS secrets |
|---|
useClientCert
boolean
advanced
Send the client certificate when connecting in order to enable
mutual TLS.
| Default | False |
|---|
verifyHostname
boolean
advanced
If true, require that the hostname of the server connected to
matches the hostname in the server's certificate.
| Default | False |
|---|
settings
object
advanced
A map containing additional settings. Each map entry has a
string name and a string value.
**Note:** In general, we recommend not changing settings from
their default values.
Status properties¶
status
string
The current state of the resource.
- `Pending`: The resource is being processed.
- `Error`: There was an error processing the resource. See
`message` for more information.
- `Ready`: The resource is ready to use.
message
string
A human-readable status message. Error messages are reported
here.
hasMatchingListener
boolean
True if there is at least one listener with a matching routing
key (usually in a remote site).
| Default | False |
|---|---|
| See also | Routing key concept |
conditions
array
advanced
A set of named conditions describing the current state of the
resource.
- `Configured`: The connector configuration has been applied
to the router.
- `Matched`: There is at least one listener corresponding to
this connector.
- `Ready`: The connector is ready to use. All other conditions
are true.
selectedPods
array
advanced