templator

package
v0.0.0-...-515e176 Latest Latest
Warning

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

Go to latest
Published: Jul 15, 2019 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FlattenToV1

func FlattenToV1(objs []runtime.Object) []*unstructured.Unstructured

FlattenToV1 expands any List-type objects into their members, and cooerces everything to v1.Unstructured. Panics if coercion encounters an unexpected object type.

func RegisterNativeFuncs

func RegisterNativeFuncs(vm *jsonnet.VM)

RegisterNativeFuncs adds kubecfg's native jsonnet functions to provided VM

Types

type JsonnetTemplator

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

JsonnetTemplator is a jsonnet based templator.

func NewJsonnetTemplator

func NewJsonnetTemplator(path string) (*JsonnetTemplator, error)

NewJsonnetTemplator returns a new Templator backed by jsonnet.

func (*JsonnetTemplator) Template

func (jt *JsonnetTemplator) Template() ([]*unstructured.Unstructured, error)

Template implements Templator.

type Templator

type Templator interface {
	Template() ([]*unstructured.Unstructured, error)
}

Templator is the interface for the templating engine.

Jump to

Keyboard shortcuts

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