kube

package
v2.4.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 24, 2026 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Overview

Package kube contains shared helpers for crossplane CLI commands that talk to a Kubernetes cluster.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ImpersonationFlags

type ImpersonationFlags struct {
	As      string   `help:"Username to impersonate for the operation. User could be a regular user or a service account in a namespace." name:"as"`
	AsGroup []string `` /* 142-byte string literal not displayed */
	AsUID   string   `` /* 129-byte string literal not displayed */
}

ImpersonationFlags are the kubectl-compatible privilege-elevation flags (--as, --as-group, --as-uid). Embed it into a command's Kong flag struct with the `embed:""` tag, then call Apply on the command's *rest.Config before building its client.

func (ImpersonationFlags) Apply

func (f ImpersonationFlags) Apply(cfg *rest.Config)

Apply sets impersonation on the given rest.Config. Unset fields and a nil cfg are no-ops, so it is always safe to call.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL