Documentation ¶
Index ¶
- func ConfigToMap(all []v1alpha1.Config) (m map[string]interface{}, err error)
- func Engine(cast *v1alpha1.CASTemplate, key string, values map[string]interface{}) (e *engine, err error)
- func MergeConfig(highPriority, lowPriority []v1alpha1.Config) (final []v1alpha1.Config)
- func UnMarshallToConfig(config string) (configs []v1alpha1.Config, err error)
- type Configurer
- type Interface
- type Kubeclient
- type KubeclientBuildOption
- type Runner
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ConfigToMap ¶
ConfigToMap transforms CAS template config type to a nested map
func Engine ¶
func Engine(cast *v1alpha1.CASTemplate, key string, values map[string]interface{}) (e *engine, err error)
Engine returns a new instance of engine
func MergeConfig ¶
MergeConfig will merge configuration fields from lowPriority that are not present in highPriority configuration and return the resulting config
Types ¶
type Configurer ¶
type Configurer interface { SetConfig(values map[string]interface{}) SetValues(key string, values map[string]interface{}) }
Configurer abstracts configuring a cas template object
type Interface ¶
type Interface interface { Configurer Runner }
Interface abstracts various operations exposed by cas template engine
type Kubeclient ¶
type Kubeclient struct {
// contains filtered or unexported fields
}
Kubeclient enables kubernetes API operationson castemplate instance
func KubeClient ¶
func KubeClient(opts ...KubeclientBuildOption) *Kubeclient
KubeClient returns a new instance of kubeclient meant for castemplate related operations
func (*Kubeclient) Get ¶
func (k *Kubeclient) Get(name string, opts metav1.GetOptions) (*apis.CASTemplate, error)
Get returns a castemplate instance for given name
type KubeclientBuildOption ¶
type KubeclientBuildOption func(*Kubeclient)
KubeclientBuildOption defines the abstraction to build a Kubeclient instance
func WithClientset ¶
func WithClientset(c *clientset.Clientset) KubeclientBuildOption
WithClientset sets the kubernetes clientset against the kubeclient instance