Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ManifestFileSuffix = []string{"yaml", "yml", "json"}
ManifestFileSuffix indictes common suffixes of files to render
Functions ¶
This section is empty.
Types ¶
type Renderer ¶
type Renderer interface {
// RenderObjects renders kubernetes objects using provided TemplateData
RenderObjects(data *TemplateData) ([]*unstructured.Unstructured, error)
DaemonSet(params *types.DaemonsetParams) (*appsv1.DaemonSet, error)
Deployment(params *types.DeploymentParams) (*appsv1.Deployment, error)
StatefulSet(params *types.StatefulSetParams) (*appsv1.StatefulSet, error)
Service(params *types.ServiceParams) (*corev1.Service, error)
ServiceAccount(params *types.ServiceAccountParams) (*corev1.ServiceAccount, error)
Role(params *types.RoleParams) (*rbacv1.Role, error)
RoleBinding(params *types.RoleBindingParams) (*rbacv1.RoleBinding, error)
SCC(params *types.SCCParams) (*securityv1.SecurityContextConstraints, error)
Ingress(params *types.IngressParams) (*networkingv1.Ingress, error)
HPA(params *types.HPAParams) (*autoscalingv2.HorizontalPodAutoscaler, error)
ServiceMonitor(params *types.ServiceMonitorParams) (*monitoringv1.ServiceMonitor, error)
}
Renderer renders k8s objects from a manifest source dir and TemplateData used by the templating engine
func NewRenderer ¶
NewRenderer creates a Renderer object, that will render all template files provided. file format needs to be either json or yaml.
type TemplateData ¶
type TemplateData struct {
// Funcs are additional Functions used during the templating process
Funcs template.FuncMap
// Data used for the rendering process
Data interface{}
}
TemplateData is used by the templating engine to render templates
Click to show internal directories.
Click to hide internal directories.