KubernetesApiSeedProvider
Ce contenu n’est pas encore disponible dans votre langue.
Defined in: src/discovery/KubernetesApiSeedProvider.ts:23
Seed provider driven by the Kubernetes API. Reads the Endpoints object for a headless Service (or any Service) and extracts the ready pod IPs.
Intentionally lightweight: we don’t ship a full K8s client. The
fetchEndpoints hook lets callers plug in either @kubernetes/client-node
or their own small fetch wrapper; the default implementation makes a
simple HTTPS call to https://kubernetes.default.svc using the standard
ServiceAccount token mount.
Address pinning (#145): pinnedAddresses restricts the accepted
pod IPs to the cluster’s own pod CIDR. An Endpoints object is free
to name addresses that no pod in the cluster owns, so this is a bound
on what a write to that object can redirect the bootstrap towards.
Implements
Section titled “Implements”Constructors
Section titled “Constructors”Constructor
Section titled “Constructor”new KubernetesApiSeedProvider(
options?):KubernetesApiSeedProvider
Defined in: src/discovery/KubernetesApiSeedProvider.ts:28
Parameters
Section titled “Parameters”options?
Section titled “options?”KubernetesApiSeedProviderOptions = {}
Returns
Section titled “Returns”KubernetesApiSeedProvider
Methods
Section titled “Methods”lookup()
Section titled “lookup()”lookup():
Promise<NodeAddress[]>
Defined in: src/discovery/KubernetesApiSeedProvider.ts:35
Return candidate seed addresses.
Returns
Section titled “Returns”Promise<NodeAddress[]>
