package
1.11.0-alpha.0
Repository: https://github.com/bertinatto/kubernetes.git
Documentation: pkg.go.dev

# Packages

No description provided by the author
Package env provides functions to incorporate environment variables into kubectl commands.
No description provided by the author
Package openapi is a collection of libraries for fetching the openapi spec from a Kubernetes server and then indexing the type definitions.
No description provided by the author

# Functions

No description provided by the author
No description provided by the author
AddDryRunFlag adds dry-run flag to a command.
No description provided by the author
AddGeneratorFlags adds flags common to resource generation commands TODO: need to take a pass at other generator commands to use this set of flags.
No description provided by the author
No description provided by the author
No description provided by the author
AddNoHeadersFlags adds no-headers flags to a command.
AddNonDeprecatedPrinterFlags supports the conversion case which must logically have output-version.
AddOutputFlags adds output related flags to a command.
AddOutputFlagsForMutation adds output related flags to a command.
AddOutputVarFlagsForMutation adds output related flags to a command.
No description provided by the author
AddPrinterFlags adds printing related flags to a command (e.g.
No description provided by the author
No description provided by the author
AddSourceToErr adds handleResourcePrefix and source string to error message.
No description provided by the author
No description provided by the author
BehaviorOnFatal allows you to override the default behavior when a fatal error occurs, which is to call os.Exit(code).
ChangeResourcePatch creates a patch between the origin input resource info and the annotated with change-cause input resource info.
CheckErr prints a user friendly error to STDERR and exits with a non-zero exit code.
No description provided by the author
ContainsChangeCause checks if input resource info contains change-cause annotation.
DefaultBehaviorOnFatal allows you to undo any previous override.
DefaultClientConfig creates a clientcmd.ClientConfig with the following hierarchy: 1.
DefaultGenerators returns the set of default generators for use in Factory instances.
DefaultSubCommandRun prints a command's help string to the specified output if no arguments (sub-commands) are provided, or a usage error otherwise.
DumpReaderToFile writes all data from the given io.Reader to the specified file (usually for temporary use).
ExtractCmdPrintOptions parses printer specific commandline args and returns a PrintOptions object.
fallbackGeneratorNameIfNecessary returns the name of the old generator if server does not support new generator.
FilterResourceList receives a list of runtime objects.
No description provided by the author
GetFirstPod returns a pod matching the namespace and label selector and the number of all pods that match the label selector.
No description provided by the author
No description provided by the author
Assumes the flag has a default value.
Assumes the flag has a default value.
Assumes the flag has a default value.
No description provided by the author
GetFlagStringArray can be used to accept multiple argument with flag repetition (e.g.
GetFlagStringSlice can be used to accept multiple argument with flag repetition (e.g.
No description provided by the author
No description provided by the author
GetResourcesAndPairs retrieves resources and "KEY=VALUE or KEY-" pair args from given args.
GetWideFlag is used to determine if "-o wide" is used.
No description provided by the author
No description provided by the author
IsSiblingCommandExists receives a pointer to a cobra command and a target string.
ManualStrip is used for dropping comments from a YAML file.
Merge requires JSON serialization TODO: merge assumes JSON serialization, and does not properly abstract API retrieval.
MultilineError returns a string representing an error that splits sub errors into their own lines.
MultipleErrors returns a newline delimited string containing the prefix and referenced errors in standard form.
MustPrintWithKinds determines if printer is dealing with multiple resource kinds, in which case it will return true, indicating resource kind will be included as part of printer output.
No description provided by the author
NewCachedDiscoveryClient creates a new DiscoveryClient.
No description provided by the author
NewClientAccessFactoryFromDiscovery allows an external caller to substitute a different discoveryFactory Which allows for the client cache to be built in ring0, but still rely on a custom discovery client.
No description provided by the author
NewFactory creates a factory with the default Kubernetes resources defined if optionalClientConfig is nil, then flags will be bound to a new clientcmd.ClientConfig.
No description provided by the author
No description provided by the author
OutputsRawFormat determines if a command's output format is machine parsable or returns false if it is human readable (name, wide, etc.).
ParsePairs retrieves new and remove pairs (if supportRemove is true) from "KEY=VALUE or KEY-" pair args.
PrintErrorWithCauses prints an error's kind, name, and each of the error's causes in a new line.
PrintFilterCount displays informational messages based on the number of resources found, hidden, or config flags shown.
No description provided by the author
RecordChangeCause annotate change-cause to input runtime object.
RequireNoArguments exits with a usage error if extra arguments are provided.
ShouldIncludeUninitialized identifies whether to include uninitialized objects.
ShouldRecord checks if we should record current change cause.
StandardErrorMessage translates common errors into a human readable message, or returns false if the error is not one of the recognized types.
StripComments will transform a YAML file into JSON, thus dropping any comments in it.
UpdateObject updates resource object with updateFn.
No description provided by the author
Retrieve a list of handled resources from printer as valid args TODO: This function implementation should be replaced with a real implementation from the discovery service.
ValidateOutputArgs validates -o flag args for mutations.
ValidResourceTypeList returns a multi-line string containing the valid resources.

# Constants

No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
TODO(sig-cli): Enforce consistent naming for generators here.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author

# Variables

ErrExit may be passed to CheckError to instruct it to output nothing but exit with status code 1.
No description provided by the author

# Structs

CachedDiscoveryClient implements the functions that discovery server-supported API groups, versions and resources.
ClientCache caches previously loaded clients for reuse, and ensures MatchServerVersion is invoked only once.
No description provided by the author

# Interfaces

BuilderFactory holds the third level of factory methods.
ClientAccessFactory holds the first level of factory methods.
No description provided by the author
Factory provides abstractions that allow the Kubectl command to be extended across multiple types of resources and different API sets.
ObjectMappingFactory holds the second level of factory methods.