mirror of
https://github.com/helmfile/helmfile.git
synced 2026-10-18 09:49:49 +02:00
* Make a few helmfile sub-commands to consistently support needs-related flags * helmfile-diff adds support for --include-transitive-needs * helmfile-template adds support for --skip-needs * helmfile-lint adds support for --skip-needs, --include-needs, and --include-transitive-needs Ref https://github.com/roboll/helmfile/issues/2055 Signed-off-by: Yusuke Kuoka <ykuoka@gmail.com> * Fix a few helmfile-lint needs related bugs and add tests Signed-off-by: Yusuke Kuoka <ykuoka@gmail.com> * Is include-transitive-needs realy working as intended? 🤔 Signed-off-by: Yusuke Kuoka <ykuoka@gmail.com> * Confirm that it does fail on unselected need by default Signed-off-by: Yusuke Kuoka <ykuoka@gmail.com> * Add missing testdata Signed-off-by: Yusuke Kuoka <ykuoka@gmail.com> * Test helmfile-template for include/skip needs support Signed-off-by: Yusuke Kuoka <ykuoka@gmail.com> * Fix a few terms Signed-off-by: Yusuke Kuoka <ykuoka@gmail.com> * Add more tests to better know the current helmfile-diff behavior around needs Signed-off-by: Yusuke Kuoka <ykuoka@gmail.com> * Fix failing tests Signed-off-by: Yusuke Kuoka <ykuoka@gmail.com> * Fix helmfile-diff to consistently handle skip/include-needs Signed-off-by: Yusuke Kuoka <ykuoka@gmail.com> * Extract testhelper.RequireLog for reusing Signed-off-by: Yusuke Kuoka <ykuoka@gmail.com> * Fix all bugs and test cases for TestDiff and TestDiff_2 Signed-off-by: Yusuke Kuoka <ykuoka@gmail.com> * Fix TestDiff_2 Signed-off-by: Yusuke Kuoka <ykuoka@gmail.com> * Fix TestDiff Signed-off-by: Yusuke Kuoka <ykuoka@gmail.com> * Fix TestDiffWithNeeds Signed-off-by: Yusuke Kuoka <ykuoka@gmail.com> * Unify behavior on including disabled releases as needs for lint and template Signed-off-by: Yusuke Kuoka <ykuoka@gmail.com> * Fix bug that --include-transitive-needs does not imply include-needs Signed-off-by: Yusuke Kuoka <ykuoka@gmail.com>
235 lines
3.3 KiB
Go
235 lines
3.3 KiB
Go
package app
|
|
|
|
import "go.uber.org/zap"
|
|
|
|
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
|
|
|
|
loggingConfig
|
|
}
|
|
|
|
type DeprecatedChartsConfigProvider interface {
|
|
Values() []string
|
|
|
|
concurrencyConfig
|
|
loggingConfig
|
|
IncludeTransitiveNeeds() bool
|
|
}
|
|
|
|
type DepsConfigProvider interface {
|
|
Args() string
|
|
SkipRepos() bool
|
|
IncludeTransitiveNeeds() bool
|
|
}
|
|
|
|
type ReposConfigProvider interface {
|
|
Args() string
|
|
IncludeTransitiveNeeds() bool
|
|
}
|
|
|
|
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
|
|
|
|
Color() bool
|
|
NoColor() bool
|
|
Context() int
|
|
DiffOutput() string
|
|
|
|
RetainValuesFiles() bool
|
|
Validate() bool
|
|
SkipCleanup() bool
|
|
SkipDiffOnInstall() bool
|
|
|
|
DAGConfig
|
|
|
|
concurrencyConfig
|
|
interactive
|
|
loggingConfig
|
|
}
|
|
|
|
type SyncConfigProvider interface {
|
|
Args() string
|
|
|
|
Values() []string
|
|
Set() []string
|
|
SkipCRDs() bool
|
|
SkipDeps() bool
|
|
Wait() bool
|
|
WaitForJobs() bool
|
|
|
|
Validate() bool
|
|
|
|
SkipNeeds() bool
|
|
IncludeNeeds() bool
|
|
IncludeTransitiveNeeds() bool
|
|
DAGConfig
|
|
|
|
concurrencyConfig
|
|
loggingConfig
|
|
}
|
|
|
|
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
|
|
|
|
DAGConfig
|
|
|
|
DetailedExitcode() bool
|
|
Color() bool
|
|
NoColor() bool
|
|
Context() int
|
|
DiffOutput() string
|
|
|
|
concurrencyConfig
|
|
}
|
|
|
|
type DeleteConfigProvider interface {
|
|
Args() string
|
|
|
|
Purge() bool
|
|
SkipDeps() bool
|
|
|
|
interactive
|
|
loggingConfig
|
|
concurrencyConfig
|
|
}
|
|
|
|
type DestroyConfigProvider interface {
|
|
Args() string
|
|
|
|
SkipDeps() bool
|
|
|
|
interactive
|
|
loggingConfig
|
|
concurrencyConfig
|
|
}
|
|
|
|
type TestConfigProvider interface {
|
|
Args() string
|
|
|
|
SkipDeps() bool
|
|
Timeout() int
|
|
Cleanup() bool
|
|
Logs() bool
|
|
|
|
concurrencyConfig
|
|
}
|
|
|
|
type LintConfigProvider interface {
|
|
Args() string
|
|
|
|
Values() []string
|
|
Set() []string
|
|
SkipDeps() bool
|
|
SkipCleanup() bool
|
|
|
|
DAGConfig
|
|
|
|
concurrencyConfig
|
|
}
|
|
|
|
type FetchConfigProvider interface {
|
|
SkipDeps() bool
|
|
OutputDir() string
|
|
|
|
concurrencyConfig
|
|
}
|
|
|
|
type TemplateConfigProvider interface {
|
|
Args() string
|
|
|
|
Values() []string
|
|
Set() []string
|
|
OutputDirTemplate() string
|
|
Validate() bool
|
|
SkipDeps() bool
|
|
SkipCleanup() bool
|
|
SkipTests() bool
|
|
OutputDir() string
|
|
IncludeCRDs() bool
|
|
|
|
DAGConfig
|
|
|
|
concurrencyConfig
|
|
}
|
|
|
|
type DAGConfig interface {
|
|
SkipNeeds() bool
|
|
IncludeNeeds() bool
|
|
IncludeTransitiveNeeds() bool
|
|
}
|
|
|
|
type WriteValuesConfigProvider interface {
|
|
Values() []string
|
|
Set() []string
|
|
OutputFileTemplate() string
|
|
SkipDeps() bool
|
|
SkipCleanup() bool
|
|
IncludeTransitiveNeeds() bool
|
|
}
|
|
|
|
type StatusesConfigProvider interface {
|
|
Args() string
|
|
|
|
concurrencyConfig
|
|
}
|
|
|
|
type StateConfigProvider interface {
|
|
EmbedValues() bool
|
|
}
|
|
|
|
type concurrencyConfig interface {
|
|
Concurrency() int
|
|
}
|
|
|
|
type loggingConfig interface {
|
|
Logger() *zap.SugaredLogger
|
|
}
|
|
|
|
type interactive interface {
|
|
Interactive() bool
|
|
}
|
|
|
|
type ListConfigProvider interface {
|
|
Output() string
|
|
}
|