util

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Nov 22, 2017 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FilterOutput

func FilterOutput(lines []string, search string, stripHeader bool) []string

func GetClientset

func GetClientset(kubeconfig string) *kubernetes.Clientset

func GetMatchingPods

func GetMatchingPods(service string, namespace string, context string, labels string) []string

func GetPods

func GetPods(namespace string, context string, labels string) []string

func GetServicePods

func GetServicePods(service string, namespace string, context string, labels string) []string

func InteractiveCommand

func InteractiveCommand(name string, args ...string)

func K8sCommandArgs

func K8sCommandArgs(args []string, namespace string, context string, labels string) []string

func RawK8sOutput

func RawK8sOutput(namespace string, context string, labels string, args ...string) []string

func RunCommand

func RunCommand(name string, args ...string) []string

func StreamCommand

func StreamCommand(c chan string, prefix string, name string, args ...string)

Types

type ColorManager

type ColorManager struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

func (*ColorManager) Colorize

func (cm *ColorManager) Colorize(s string) string

func (*ColorManager) GetColor

func (cm *ColorManager) GetColor() color.Attribute

func (*ColorManager) GetPrefix

func (cm *ColorManager) GetPrefix(prefix string) string

type OutputManager

type OutputManager struct {
	sync.RWMutex

	HeaderColumns []string
	// contains filtered or unexported fields
}

func (*OutputManager) Append

func (o *OutputManager) Append(s ...string)

func (*OutputManager) GetOutput

func (o *OutputManager) GetOutput() []string

func (*OutputManager) Print

func (o *OutputManager) Print()

Jump to

Keyboard shortcuts

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