rubykube

package
v0.0.0-...-b08ae9a Latest Latest
Warning

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

Go to latest
Published: Feb 10, 2018 License: Apache-2.0 Imports: 21 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewParamsCollection

func NewParamsCollection(hash *mruby.MrbValue, spec params) (*paramsCollection, error)

func ValidString

func ValidString(value *mruby.MrbValue) *string

Types

type Classes

type Classes struct {
	Root *mruby.Class

	Pods *podsClass
	Pod  *podClass

	Service  *serviceClass
	Services *servicesClass

	Deployments *deploymentsClass
	Deployment  *deploymentClass

	ReplicaSets *replicaSetsClass
	ReplicaSet  *replicaSetClass

	DaemonSets *daemonSetsClass
	DaemonSet  *daemonSetClass

	PodLogs *podLogsClass

	PodMaker *podMakerClass

	LabelSelector  *labelSelectorClass
	LabelCollector *labelCollectorClass
	LabelKey       *labelKeyClass

	FieldSelector  *fieldSelectorClass
	FieldCollector *fieldCollectorClass
	FieldKey       *fieldKeyClass
}

type CurrentState

type CurrentState struct {
	Namespace string
	Cluster   string
	Context   string
}

type RubyKube

type RubyKube struct {
	// contains filtered or unexported fields
}

func NewRubyKube

func NewRubyKube(omitFuncs []string, rl *readline.Instance) (*RubyKube, error)

NewRubyKube may return an error on mruby or k8s.io/client-go issues.

func (*RubyKube) AddVerb

func (rk *RubyKube) AddVerb(name string, fn verbFunc, args mruby.ArgSpec)

AddVerb adds a function to the mruby dispatch as well as adding hooks around the call to ensure containers are committed and intermediate layers are cleared.

func (*RubyKube) Close

func (rk *RubyKube) Close() error

Close tears down all functions of the RubyKube, preparing it for exit.

func (*RubyKube) GetDefaultNamespace

func (rk *RubyKube) GetDefaultNamespace(override string) string

func (*RubyKube) GetNamespace

func (rk *RubyKube) GetNamespace(override string) string

func (*RubyKube) Mrb

func (rk *RubyKube) Mrb() *mruby.Mrb

Mrb returns the mrb (mruby) instance the builder is using.

func (*RubyKube) MultiLinePrompt

func (rk *RubyKube) MultiLinePrompt()

func (*RubyKube) NormalPrompt

func (rk *RubyKube) NormalPrompt()

func (*RubyKube) Run

func (rk *RubyKube) Run(script string) (*mruby.MrbValue, error)

Run the script.

func (*RubyKube) RunCode

func (rk *RubyKube) RunCode(block *mruby.MrbValue, stackKeep int) (*mruby.MrbValue, int, error)

RunCode runs the ruby value (a proc) and returns the result.

func (*RubyKube) SetNamespace

func (rk *RubyKube) SetNamespace(ns string)

Source Files

Directories

Path Synopsis
templates

Jump to

Keyboard shortcuts

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