Documentation ¶
Index ¶
- Variables
- func FindEnvVar(pod v1.Pod, envName string) (*v1.EnvVar, error)
- func NewConfigLoader(kubeconfig, context string) clientcmd.ClientConfig
- type KubeClient
- func (client KubeClient) Exec(ctx context.Context, pod v1.Pod, cmd string, stdin io.Reader, ...) error
- func (client KubeClient) FilterPodList(pods *v1.PodList, queries []LabelQueryable) (foundPods []v1.Pod, err error)
- func (client KubeClient) GetNamespacedPods(ctx context.Context) (*v1.PodList, error)
- func (client KubeClient) GetPodsFiltered(ctx context.Context, queries []LabelQueryable) ([]v1.Pod, error)
- func (client KubeClient) GetValueFromEnv(ctx context.Context, pod v1.Pod, envNames []string) (string, error)
- func (client KubeClient) Namespaces() v1.NamespaceInterface
- func (client KubeClient) Pods() v1.PodInterface
- func (client KubeClient) Secrets() v1.SecretInterface
- type LabelQuery
- type LabelQueryAnd
- type LabelQueryable
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrNoEnvNames = errors.New("dialect does not contain any env names") ErrSecretDoesNotHaveKey = errors.New("secret does not have key") )
View Source
var ErrEnvVarNotFound = errors.New("env var not found")
View Source
var ErrNoPods = errors.New("no pods in namespace")
View Source
var ErrPodNotFound = errors.New("no pods with matching label")
Functions ¶
func NewConfigLoader ¶ added in v1.4.3
func NewConfigLoader(kubeconfig, context string) clientcmd.ClientConfig
Types ¶
type KubeClient ¶
type KubeClient struct { ClientSet kubernetes.Interface ClientConfig *rest.Config Namespace string }
func NewClient ¶
func NewClient(kubeconfig, context, namespace string) (config KubeClient, err error)
func NewClientFromCmd ¶
func NewClientFromCmd(cmd *cobra.Command) (KubeClient, error)
func (KubeClient) FilterPodList ¶
func (client KubeClient) FilterPodList(pods *v1.PodList, queries []LabelQueryable) (foundPods []v1.Pod, err error)
func (KubeClient) GetNamespacedPods ¶
func (KubeClient) GetPodsFiltered ¶
func (client KubeClient) GetPodsFiltered(ctx context.Context, queries []LabelQueryable) ([]v1.Pod, error)
func (KubeClient) GetValueFromEnv ¶
func (KubeClient) Namespaces ¶
func (client KubeClient) Namespaces() v1.NamespaceInterface
func (KubeClient) Pods ¶
func (client KubeClient) Pods() v1.PodInterface
func (KubeClient) Secrets ¶
func (client KubeClient) Secrets() v1.SecretInterface
type LabelQuery ¶
Click to show internal directories.
Click to hide internal directories.