kubectlk8s.io/kubectl/pkg/cmd/describe Index | Files

package describe

import "k8s.io/kubectl/pkg/cmd/describe"

Index

Functions

func NewCmdDescribe

func NewCmdDescribe(parent string, f cmdutil.Factory, streams genericiooptions.IOStreams) *cobra.Command

Types

type DescribeFlags

type DescribeFlags struct {
	Factory           cmdutil.Factory
	Selector          string
	AllNamespaces     bool
	FilenameOptions   *resource.FilenameOptions
	DescriberSettings *describe.DescriberSettings
	genericiooptions.IOStreams
}

DescribeFlags directly reflect the information that CLI is gathering via flags. They will be converted to Options, which reflect the runtime requirements for the command.

func NewDescribeFlags

func NewDescribeFlags(f cmdutil.Factory, streams genericiooptions.IOStreams) *DescribeFlags

NewDescribeFlags returns a default DescribeFlags

func (*DescribeFlags) AddFlags

func (flags *DescribeFlags) AddFlags(cmd *cobra.Command)

AddFlags registers flags for a cli

func (*DescribeFlags) ToOptions

func (flags *DescribeFlags) ToOptions(parent string, args []string) (*DescribeOptions, error)

ToOptions converts from CLI inputs to runtime input

type DescribeOptions

type DescribeOptions struct {
	CmdParent string
	Selector  string
	Namespace string

	Describer  func(*meta.RESTMapping) (describe.ResourceDescriber, error)
	NewBuilder func() *resource.Builder

	BuilderArgs []string

	EnforceNamespace bool
	AllNamespaces    bool

	DescriberSettings *describe.DescriberSettings
	FilenameOptions   *resource.FilenameOptions

	genericiooptions.IOStreams
}

func (*DescribeOptions) DescribeMatchingResources

func (o *DescribeOptions) DescribeMatchingResources(originalError error, resource, prefix string) error

func (*DescribeOptions) Run

func (o *DescribeOptions) Run() error

func (*DescribeOptions) Validate

func (o *DescribeOptions) Validate() error

Source Files

describe.go

Version
v0.32.3 (latest)
Published
Mar 12, 2025
Platform
linux/amd64
Imports
14 packages
Last checked
6 days ago

Tools for package owners.