Documentation
¶
Index ¶
- func NewBackupCommand() *cobra.Command
- func NewBackupsGenerateCommand() *cobra.Command
- func NewRestoreCommand() *cobra.Command
- type SnippetGenerationCommand
- type Templating
- func (t *Templating) LoadVariables(path string) (map[string]interface{}, error)
- func (t *Templating) RenderChart(script string, gpgKeyContent string, schedule string, jobName string, ...) (string, error)
- func (t *Templating) RenderTemplate(name string, operation string, variables interface{}) (string, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewBackupCommand ¶
func NewBackupsGenerateCommand ¶
NewBackupsGenerateCommand creates the new command
func NewRestoreCommand ¶
Types ¶
type SnippetGenerationCommand ¶
type SnippetGenerationCommand struct { Template string DefinitionFile string IsKubernetes bool KeyPath string OutputDir string Schedule string JobName string Image string Operation string Namespace string }
func (*SnippetGenerationCommand) Run ¶
func (c *SnippetGenerationCommand) Run() error
type Templating ¶
type Templating struct{}
func (*Templating) LoadVariables ¶
func (t *Templating) LoadVariables(path string) (map[string]interface{}, error)
func (*Templating) RenderChart ¶
func (t *Templating) RenderChart(script string, gpgKeyContent string, schedule string, jobName string, image string, valuesOverride map[interface{}]interface{}, namespace string) (string, error)
RenderChart Renders YAML files from 'chart/templates' directory combining Helm values from CLI switches and from .HelmValues
func (*Templating) RenderTemplate ¶
func (t *Templating) RenderTemplate(name string, operation string, variables interface{}) (string, error)
RenderTemplate renders a Go-formatted template in order from (stops on first found):
~/.rkc/backups/templates/{backup,restore}/{Name}.tmpl
~/.rkc/backups/templates/base/{backup,restore}/{Name}.tmpl
Templates in first directory are replaced only if the user has not modified them.
Click to show internal directories.
Click to hide internal directories.