Documentation

Overview

Package kube implements "kube" starlark built-in which renders and applies Kubernetes objects.

Index

Constants

This section is empty.

Variables

View Source
var ErrNotFound = errors.New("not found")
View Source
var ErrUpdateImmutable = errors.New("cannot update immutable. Use -force to delete and recreate")

Functions

func ErrImmutableRessource

func ErrImmutableRessource(attribute string, obj runtime.Object) error

func New

func New(
	addr string,
	d discovery.DiscoveryInterface,
	dynC dynamic.Interface,
	c *http.Client,
	dryRun, force, diff bool,
	diffFilters []string,
) starlark.HasAttrs

New returns a new skaylark.HasAttrs object for kube package.

func NewFake

func NewFake(force bool) (m starlark.HasAttrs, closeFn func(), err error)

NewFake returns a new fake kube module for testing. It takes a bool attribute to determine if the starkalrk.HasAttrs object should forcefully update resources

Types

type DynamicClient

type DynamicClient interface {
	Apply(t *starlark.Thread, name string, namespace string, data *starlark.List) (starlark.Value, error)
}

DynamicClient used for applying dynamic resource manifests with no predefined protobufs such as CRDs.