Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/kubernetes_client/transports/mod.ts

Typescript library for accessing a Kubernetes API server
Go to Latest
import * as kubernetesClient from "https://deno.land/x/kubernetes_client@v0.7.0/transports/mod.ts";

Classes

A RestClient which uses a KubeConfig to talk directly to a Kubernetes endpoint. Used by code which is running within a Kubernetes pod and would like to access the local cluster's control plane using its Service Account.

A RestClient for easily running on a developer's local machine. Your existing kubectl is called to do all the actual authentication and network stuff. This is pretty reliable but mot all types of requests can be performed this way.

Functions

Automatic trial-and-error approach for deciding how to talk to Kubernetes. Influenced by Deno's current permissions and Deno may prompt for more permissions. Will emit a list of problems if no usable clients are found. You'll likely want to set the correct Deno permissions for your installation.

Constructs the typical list of Kubernetes API clients, using an alternative client for connecting to KubeConfig contexts. The Kubectl client is unaffected by this.