options

package
v1.8.0-rc1 Latest Latest
Warning

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

Go to latest
Published: Dec 6, 2024 License: Apache-2.0 Imports: 13 Imported by: 13

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ArgoRolloutsOptions

type ArgoRolloutsOptions struct {
	CLIName          string
	RESTClientGetter genericclioptions.RESTClientGetter
	ConfigFlags      *genericclioptions.ConfigFlags
	KlogLevel        int
	LogLevel         string
	RolloutsClient   roclientset.Interface
	KubeClient       kubernetes.Interface
	DynamicClient    dynamic.Interface

	Log *log.Logger
	genericclioptions.IOStreams

	Now func() metav1.Time
}

ArgoRolloutsOptions are a set of common CLI flags and convenience functions made available to all commands of the kubectl-argo-rollouts plugin

func NewArgoRolloutsOptions

func NewArgoRolloutsOptions(streams genericclioptions.IOStreams) *ArgoRolloutsOptions

NewArgoRolloutsOptions provides an instance of ArgoRolloutsOptions with default values

func (*ArgoRolloutsOptions) AddKubectlFlags

func (o *ArgoRolloutsOptions) AddKubectlFlags(cmd *cobra.Command)

AddKubectlFlags adds kubectl related flags to the command

func (*ArgoRolloutsOptions) DynamicClientset added in v0.9.1

func (o *ArgoRolloutsOptions) DynamicClientset() dynamic.Interface

DynamicClientset returns a Dynamic client interface based on client flags

func (*ArgoRolloutsOptions) Example

func (o *ArgoRolloutsOptions) Example(example string) string

Example returns the example string with the CLI command replaced in the example

func (*ArgoRolloutsOptions) KubeClientset

func (o *ArgoRolloutsOptions) KubeClientset() kubernetes.Interface

KubeClientset returns a Kubernetes client interface based on client flags

func (*ArgoRolloutsOptions) Namespace

func (o *ArgoRolloutsOptions) Namespace() string

Namespace returns the namespace based on client flags or kube context

func (*ArgoRolloutsOptions) PersistentPreRunE

func (o *ArgoRolloutsOptions) PersistentPreRunE(c *cobra.Command, args []string) error

PersistentPreRunE contains common logic which will be executed for all commands

func (*ArgoRolloutsOptions) RolloutsClientset

func (o *ArgoRolloutsOptions) RolloutsClientset() roclientset.Interface

RolloutsClientset returns a Rollout client interface based on client flags

func (*ArgoRolloutsOptions) UsageErr

func (o *ArgoRolloutsOptions) UsageErr(c *cobra.Command) error

UsageErr is a convenience function to output usage and return an error

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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