api

package
v0.2.1 Latest Latest
Warning

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

Go to latest
Published: Jan 28, 2015 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Overview

Package api defines and registers types for Template objects.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Parameter

type Parameter struct {
	// Required: Parameter name must be set and it can be referenced in Template
	// Items using ${PARAMETER_NAME}
	Name string `json:"name"`

	// Optional: Parameter can have description
	Description string `json:"description,omitempty"`

	// Optional: Generate specifies the generator to be used to generate
	// random string from an input value specified by From field. The result
	// string is stored into Value field. If empty, no generator is being
	// used, leaving the result Value untouched.
	Generate string `json:"generate,omitempty"`

	// Optional: From is an input value for the generator.
	From string `json:"from,omitempty"`

	// Optional: Value holds the Parameter data. The Value data can be
	// overwritten by the generator. The value replaces all occurances
	// of the Parameter ${Name} expression during the Template to Config
	// transformation.
	Value string `json:"value,omitempty"`
}

Parameter defines a name/value variable that is to be processed during the Template to Config transformation.

type Template

type Template struct {
	kapi.TypeMeta   `json:",inline"`
	kapi.ObjectMeta `json:"metadata,omitempty"`

	// Required: Items is an array of Kubernetes resources of Service,
	// Pod and/or ReplicationController kind.
	// TODO: Handle unregistered types. Define custom []runtime.Object
	//       type and its unmarshaller instead of []runtime.Object.
	Items []runtime.RawExtension `json:"items"`

	// Optional: Parameters is an array of Parameters used during the
	// Template to Config transformation.
	Parameters []Parameter `json:"parameters,omitempty"`
}

Template contains the inputs needed to produce a Config.

func (*Template) IsAnAPIObject

func (*Template) IsAnAPIObject()

Directories

Path Synopsis
Package validation has functions for validating the correctness of Template objects and explaining what is wrong with them when they aren't valid.
Package validation has functions for validating the correctness of Template objects and explaining what is wrong with them when they aren't valid.

Jump to

Keyboard shortcuts

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