set

package
v1.5.0-beta.1 Latest Latest
Warning

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

Go to latest
Published: Nov 18, 2016 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewCmdImage

func NewCmdImage(f cmdutil.Factory, out, err io.Writer) *cobra.Command

func NewCmdResources

func NewCmdResources(f cmdutil.Factory, out io.Writer, errOut io.Writer) *cobra.Command

func NewCmdSet

func NewCmdSet(f cmdutil.Factory, out, err io.Writer) *cobra.Command

Types

type ImageOptions

type ImageOptions struct {
	resource.FilenameOptions

	Mapper      meta.RESTMapper
	Typer       runtime.ObjectTyper
	Infos       []*resource.Info
	Encoder     runtime.Encoder
	Selector    string
	Out         io.Writer
	Err         io.Writer
	ShortOutput bool
	All         bool
	Record      bool
	ChangeCause string
	Local       bool
	Cmd         *cobra.Command

	PrintObject            func(cmd *cobra.Command, mapper meta.RESTMapper, obj runtime.Object, out io.Writer) error
	UpdatePodSpecForObject func(obj runtime.Object, fn func(*api.PodSpec) error) (bool, error)
	Resources              []string
	ContainerImages        map[string]string
	// contains filtered or unexported fields
}

ImageOptions is the start of the data required to perform the operation. As new fields are added, add them here instead of referencing the cmd.Flags()

func (*ImageOptions) Complete

func (o *ImageOptions) Complete(f cmdutil.Factory, cmd *cobra.Command, args []string) error

func (*ImageOptions) Run

func (o *ImageOptions) Run() error

func (*ImageOptions) Validate

func (o *ImageOptions) Validate() error

type Patch

type Patch struct {
	Info *resource.Info
	Err  error

	Before []byte
	After  []byte
	Patch  []byte
}

Patch represents the result of a mutation to an object.

func CalculatePatches

func CalculatePatches(f cmdutil.Factory, infos []*resource.Info, encoder runtime.Encoder, local bool, mutateFn func(*resource.Info) (bool, error)) []*Patch

CalculatePatches calls the mutation function on each provided info object, and generates a strategic merge patch for the changes in the object. Encoder must be able to encode the info into the appropriate destination type. If mutateFn returns false, the object is not included in the final list of patches. If local is true, it will be default to use SMPatchVersionLatest to calculate a patch without contacting the server to get the server supported SMPatchVersion. If you are using a patch's Patch field generated in local mode, be careful. If local is false, it will talk to the server to check which StategicMergePatchVersion to use.

type ResourcesOptions

type ResourcesOptions struct {
	resource.FilenameOptions

	Mapper            meta.RESTMapper
	Typer             runtime.ObjectTyper
	Infos             []*resource.Info
	Encoder           runtime.Encoder
	Out               io.Writer
	Err               io.Writer
	Selector          string
	ContainerSelector string
	ShortOutput       bool
	All               bool
	Record            bool
	ChangeCause       string
	Local             bool
	Cmd               *cobra.Command

	Limits               string
	Requests             string
	ResourceRequirements api.ResourceRequirements

	PrintObject            func(cmd *cobra.Command, mapper meta.RESTMapper, obj runtime.Object, out io.Writer) error
	UpdatePodSpecForObject func(obj runtime.Object, fn func(*api.PodSpec) error) (bool, error)
	Resources              []string
	// contains filtered or unexported fields
}

ResourcesOptions is the start of the data required to perform the operation. As new fields are added, add them here instead of referencing the cmd.Flags

func (*ResourcesOptions) Complete

func (o *ResourcesOptions) Complete(f cmdutil.Factory, cmd *cobra.Command, args []string) error

func (*ResourcesOptions) Run

func (o *ResourcesOptions) Run() error

func (*ResourcesOptions) Validate

func (o *ResourcesOptions) Validate() error

Jump to

Keyboard shortcuts

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