app

package
v0.144.0 Latest Latest
Warning

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

Go to latest
Published: Mar 31, 2022 License: MIT Imports: 28 Imported by: 4

Documentation

Index

Constants

View Source
const (
	DefaultHelmfile              = "helmfile.yaml"
	DeprecatedHelmfile           = "charts.yaml"
	DefaultHelmfileDirectory     = "helmfile.d"
	ExperimentalEnvVar           = "HELMFILE_EXPERIMENTAL"         // environment variable for experimental features, expecting "true" lower case
	ExperimentalSelectorExplicit = "explicit-selector-inheritance" // value to remove default selector inheritance to sub-helmfiles and use the explicit one
)
View Source
const (
	DefaultHelmBinary = state.DefaultHelmBinary
)

Variables

View Source
var (
	SetReverse = func(r bool) func(o *LoadOpts) {
		return func(o *LoadOpts) {
			o.Reverse = r
		}
	}

	SetRetainValuesFiles = func(r bool) func(o *LoadOpts) {
		return func(o *LoadOpts) {
			o.RetainValuesFiles = true
		}
	}

	SetFilter = func(f bool) func(o *LoadOpts) {
		return func(o *LoadOpts) {
			o.Filter = f
		}
	}
)

Functions

func AskForConfirmation added in v0.70.0

func AskForConfirmation(s string) bool

Copyright (c) 2017 Roland Singer [roland.singer@desertbit.com]

Shamelessly borrowed from @r0l1's awesome work that is available at https://gist.github.com/r0l1/3dcbb0c8f6cfe9c66ab8008f55f8f28b

func FormatAsJson added in v0.110.0

func FormatAsJson(releases []*HelmRelease) error

func FormatAsTable added in v0.110.0

func FormatAsTable(releases []*HelmRelease) error

Types

type App

type App struct {
	OverrideKubeContext string
	OverrideHelmBinary  string

	Logger      *zap.SugaredLogger
	Env         string
	Namespace   string
	Chart       string
	Selectors   []string
	Args        string
	ValuesFiles []string
	Set         map[string]interface{}

	FileOrDir string
	// contains filtered or unexported fields
}

func Init

func Init(app *App) *App

func New added in v0.70.0

func New(conf ConfigProvider) *App

func (*App) Apply added in v0.70.0

func (a *App) Apply(c ApplyConfigProvider) error

func (*App) CleanCacheDir added in v0.143.1

func (a *App) CleanCacheDir(c ListConfigProvider) error

func (*App) Delete added in v0.70.0

func (a *App) Delete(c DeleteConfigProvider) error

func (*App) DeprecatedSyncCharts added in v0.70.0

func (a *App) DeprecatedSyncCharts(c DeprecatedChartsConfigProvider) error

func (*App) Deps added in v0.70.0

func (a *App) Deps(c DepsConfigProvider) error

func (*App) Destroy added in v0.70.0

func (a *App) Destroy(c DestroyConfigProvider) error

func (*App) Diff added in v0.70.0

func (a *App) Diff(c DiffConfigProvider) error

func (*App) Fetch added in v0.139.0

func (a *App) Fetch(c FetchConfigProvider) error

func (*App) ForEachState added in v0.70.0

func (a *App) ForEachState(do func(*Run) (bool, []error), includeTransitiveNeeds bool, o ...LoadOption) error

func (*App) Lint added in v0.70.0

func (a *App) Lint(c LintConfigProvider) error

func (*App) ListReleases added in v0.82.0

func (a *App) ListReleases(c ListConfigProvider) error

func (*App) PrintState added in v0.82.0

func (a *App) PrintState(c StateConfigProvider) error

func (*App) Repos added in v0.70.0

func (a *App) Repos(c ReposConfigProvider) error

func (*App) ShowCacheDir added in v0.143.1

func (a *App) ShowCacheDir(c ListConfigProvider) error

func (*App) Status added in v0.70.0

func (a *App) Status(c StatusesConfigProvider) error

func (*App) Sync added in v0.70.0

func (a *App) Sync(c SyncConfigProvider) error

func (*App) Template added in v0.70.0

func (a *App) Template(c TemplateConfigProvider) error

func (*App) Test added in v0.70.0

func (a *App) Test(c TestConfigProvider) error

func (*App) Wrap added in v0.90.3

func (a *App) Wrap(converge func(*state.HelmState, helmexec.Interface) []error) func(st *state.HelmState, helm helmexec.Interface, includeTransitiveNeeds bool) (bool, []error)

func (*App) WrapWithoutSelector added in v0.139.0

func (a *App) WrapWithoutSelector(converge func(*state.HelmState, helmexec.Interface) []error) func(st *state.HelmState, helm helmexec.Interface) (bool, []error)

func (*App) WriteValues added in v0.129.0

func (a *App) WriteValues(c WriteValuesConfigProvider) error

type ApplyConfigProvider added in v0.70.0

type ApplyConfigProvider interface {
	Args() string

	Values() []string
	Set() []string
	SkipCRDs() bool
	SkipDeps() bool
	Wait() bool
	WaitForJobs() bool

	IncludeTests() bool

	Suppress() []string
	SuppressSecrets() bool
	ShowSecrets() bool
	SuppressDiff() bool

	DetailedExitcode() bool

	NoColor() bool
	Context() int
	DiffOutput() string

	RetainValuesFiles() bool
	Validate() bool
	SkipCleanup() bool
	SkipDiffOnInstall() bool

	SkipNeeds() bool
	IncludeNeeds() bool
	IncludeTransitiveNeeds() bool
	// contains filtered or unexported methods
}

type ConfigProvider added in v0.70.0

type ConfigProvider interface {
	Args() string
	HelmBinary() string

	FileOrDir() string
	KubeContext() string
	Namespace() string
	Chart() string
	Selectors() []string
	StateValuesSet() map[string]interface{}
	StateValuesFiles() []string
	Env() string
	// contains filtered or unexported methods
}

type Context

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

func NewContext

func NewContext() Context

func (Context) SyncReposOnce

func (ctx Context) SyncReposOnce(st *state.HelmState, helm state.RepoUpdater) error

type DeleteConfigProvider added in v0.70.0

type DeleteConfigProvider interface {
	Args() string

	Purge() bool
	SkipDeps() bool
	// contains filtered or unexported methods
}

type DeprecatedChartsConfigProvider added in v0.70.0

type DeprecatedChartsConfigProvider interface {
	Values() []string

	IncludeTransitiveNeeds() bool
	// contains filtered or unexported methods
}

type DepsConfigProvider added in v0.70.0

type DepsConfigProvider interface {
	Args() string
	SkipRepos() bool
	IncludeTransitiveNeeds() bool
}

type DestroyConfigProvider added in v0.70.0

type DestroyConfigProvider interface {
	Args() string

	SkipDeps() bool
	// contains filtered or unexported methods
}

type DiffConfigProvider added in v0.70.0

type DiffConfigProvider interface {
	Args() string

	Values() []string
	Set() []string
	Validate() bool
	SkipCRDs() bool
	SkipDeps() bool

	IncludeTests() bool

	Suppress() []string
	SuppressSecrets() bool
	ShowSecrets() bool
	SuppressDiff() bool
	SkipDiffOnInstall() bool

	SkipNeeds() bool
	IncludeNeeds() bool

	DetailedExitcode() bool
	NoColor() bool
	Context() int
	DiffOutput() string
	// contains filtered or unexported methods
}

type Error added in v0.60.0

type Error struct {
	Errors []error
	// contains filtered or unexported fields
}

func (*Error) Code added in v0.60.0

func (e *Error) Code() int

func (*Error) Error added in v0.60.0

func (e *Error) Error() string

type FetchConfigProvider added in v0.139.0

type FetchConfigProvider interface {
	SkipDeps() bool
	OutputDir() string
	// contains filtered or unexported methods
}

type HelmRelease added in v0.110.0

type HelmRelease struct {
	Name      string `json:"name"`
	Namespace string `json:"namespace"`
	Enabled   bool   `json:"enabled"`
	Installed bool   `json:"installed"`
	Labels    string `json:"labels"`
	Chart     string `json:"chart"`
	Version   string `json:"version"`
}

type LintConfigProvider added in v0.70.0

type LintConfigProvider interface {
	Args() string

	Values() []string
	Set() []string
	SkipDeps() bool
	SkipCleanup() bool
	// contains filtered or unexported methods
}

type ListConfigProvider added in v0.110.0

type ListConfigProvider interface {
	Output() string
}

type LoadOption added in v0.106.0

type LoadOption func(o *LoadOpts)

type LoadOpts added in v0.68.0

type LoadOpts struct {
	Selectors   []string
	Environment state.SubhelmfileEnvironmentSpec

	RetainValuesFiles bool

	// CalleePath is the absolute path to the file being loaded
	CalleePath string

	Reverse bool

	Filter bool
}

func (LoadOpts) DeepCopy added in v0.70.0

func (o LoadOpts) DeepCopy() LoadOpts

type MultiError added in v0.139.3

type MultiError struct {
	Errors []error
}

func (*MultiError) Error added in v0.139.3

func (e *MultiError) Error() string

type NoMatchingHelmfileError

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

func (*NoMatchingHelmfileError) Error

func (e *NoMatchingHelmfileError) Error() string

type Opts added in v0.90.3

type Opts struct {
	DAGEnabled bool
}

type RenderOpts added in v0.68.0

type RenderOpts struct {
}

type ReposConfigProvider added in v0.70.0

type ReposConfigProvider interface {
	Args() string
	IncludeTransitiveNeeds() bool
}

type Run added in v0.70.0

type Run struct {
	ReleaseToChart map[state.PrepareChartKey]string

	Ask func(string) bool
	// contains filtered or unexported fields
}

func NewRun added in v0.70.0

func NewRun(st *state.HelmState, helm helmexec.Interface, ctx Context) *Run

func (*Run) DeprecatedSyncCharts added in v0.70.0

func (r *Run) DeprecatedSyncCharts(c DeprecatedChartsConfigProvider) []error

func (*Run) Deps added in v0.70.0

func (r *Run) Deps(c DepsConfigProvider) []error

func (*Run) Repos added in v0.70.0

func (r *Run) Repos(c ReposConfigProvider) error

type StateConfigProvider added in v0.82.0

type StateConfigProvider interface {
	EmbedValues() bool
}

type StatusesConfigProvider added in v0.70.0

type StatusesConfigProvider interface {
	Args() string
	// contains filtered or unexported methods
}

type SyncConfigProvider added in v0.70.0

type SyncConfigProvider interface {
	Args() string

	Values() []string
	Set() []string
	SkipCRDs() bool
	SkipDeps() bool
	Wait() bool
	WaitForJobs() bool

	SkipNeeds() bool
	IncludeNeeds() bool
	IncludeTransitiveNeeds() bool
	// contains filtered or unexported methods
}

type TemplateConfigProvider added in v0.70.0

type TemplateConfigProvider interface {
	Args() string

	Values() []string
	Set() []string
	OutputDirTemplate() string
	Validate() bool
	SkipDeps() bool
	SkipCleanup() bool
	SkipTests() bool
	OutputDir() string
	IncludeCRDs() bool
	IncludeNeeds() bool
	IncludeTransitiveNeeds() bool
	// contains filtered or unexported methods
}

type TestConfigProvider added in v0.70.0

type TestConfigProvider interface {
	Args() string

	SkipDeps() bool
	Timeout() int
	Cleanup() bool
	Logs() bool
	// contains filtered or unexported methods
}

type WriteValuesConfigProvider added in v0.129.0

type WriteValuesConfigProvider interface {
	Values() []string
	Set() []string
	OutputFileTemplate() string
	SkipDeps() bool
	SkipCleanup() bool
	IncludeTransitiveNeeds() bool
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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