kubecfg

package
v0.10.0 Latest Latest
Warning

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

Go to latest
Published: Apr 26, 2018 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrDiffFound = fmt.Errorf("Differences found.")

Functions

This section is empty.

Types

type Client

type Client struct {
	ClientPool dynamic.ClientPool
	Discovery  discovery.DiscoveryInterface
	Namespace  string
	// Name of the remote client to identify changes against. This field is Optional.
	Name string
	// APIObjects are the Kubernetes objects being diffed against
	APIObjects []*unstructured.Unstructured
}

Client holds the necessary information to connect with a remote Kubernetes cluster.

type Diff

type Diff struct {
	DiffStrategy string
}

Diff is a base representation of the `diff` functionality.

type DiffCmd

type DiffCmd interface {
	Run(out io.Writer) error
}

DiffCmd is an interface containing a set of functions that allow diffing between two sets of data containing Kubernetes resouces.

type DiffLocalCmd

type DiffLocalCmd struct {
	Diff
	Env1 *LocalEnv
	Env2 *LocalEnv
}

DiffLocalCmd extends DiffCmd and is meant to represent diffing between two sets of Kubernetes objects.

func (*DiffLocalCmd) Run

func (c *DiffLocalCmd) Run(out io.Writer) error

type DiffRemoteCmd

type DiffRemoteCmd struct {
	Diff
	Client *Client
}

DiffRemoteCmd extends DiffCmd and is meant to represent diffing between some set of Kubernetes objects and the Kubernetes objects located on a remote client.

func (*DiffRemoteCmd) Run

func (c *DiffRemoteCmd) Run(out io.Writer) error

type DiffRemotesCmd

type DiffRemotesCmd struct {
	Diff
	ClientA *Client
	ClientB *Client
}

DiffRemotesCmd extends DiffCmd and is meant to represent diffing between the Kubernetes objects on two remote clients.

func (*DiffRemotesCmd) Run

func (c *DiffRemotesCmd) Run(out io.Writer) error

type LocalEnv

type LocalEnv struct {
	Name       string
	APIObjects []*unstructured.Unstructured
}

LocalEnv holds the local Kubernetes objects for an environment and relevant environment details, such as, environment name

Jump to

Keyboard shortcuts

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