mirror of
https://github.com/helmfile/helmfile.git
synced 2026-10-19 01:45:37 +02:00
Fix destory, delete, and test to work with chartify on local chart with dependencies that are not yet downloaded (#1801)
Fixes #1800
This commit is contained in:
+6
-6
@@ -396,8 +396,8 @@ func (a *App) Status(c StatusesConfigProvider) error {
|
||||
func (a *App) Delete(c DeleteConfigProvider) error {
|
||||
return a.ForEachState(func(run *Run) (ok bool, errs []error) {
|
||||
err := run.withPreparedCharts("delete", state.ChartPrepareOptions{
|
||||
SkipRepos: true,
|
||||
SkipDeps: true,
|
||||
SkipRepos: c.SkipDeps(),
|
||||
SkipDeps: c.SkipDeps(),
|
||||
}, func() {
|
||||
ok, errs = a.delete(run, c.Purge(), c)
|
||||
})
|
||||
@@ -413,8 +413,8 @@ func (a *App) Delete(c DeleteConfigProvider) error {
|
||||
func (a *App) Destroy(c DestroyConfigProvider) error {
|
||||
return a.ForEachState(func(run *Run) (ok bool, errs []error) {
|
||||
err := run.withPreparedCharts("destroy", state.ChartPrepareOptions{
|
||||
SkipRepos: true,
|
||||
SkipDeps: true,
|
||||
SkipRepos: c.SkipDeps(),
|
||||
SkipDeps: c.SkipDeps(),
|
||||
}, func() {
|
||||
ok, errs = a.delete(run, true, c)
|
||||
})
|
||||
@@ -436,8 +436,8 @@ func (a *App) Test(c TestConfigProvider) error {
|
||||
}
|
||||
|
||||
err := run.withPreparedCharts("test", state.ChartPrepareOptions{
|
||||
SkipRepos: true,
|
||||
SkipDeps: true,
|
||||
SkipRepos: c.SkipDeps(),
|
||||
SkipDeps: c.SkipDeps(),
|
||||
}, func() {
|
||||
errs = a.test(run, c)
|
||||
})
|
||||
|
||||
@@ -114,6 +114,7 @@ type DeleteConfigProvider interface {
|
||||
Args() string
|
||||
|
||||
Purge() bool
|
||||
SkipDeps() bool
|
||||
|
||||
interactive
|
||||
loggingConfig
|
||||
@@ -123,6 +124,8 @@ type DeleteConfigProvider interface {
|
||||
type DestroyConfigProvider interface {
|
||||
Args() string
|
||||
|
||||
SkipDeps() bool
|
||||
|
||||
interactive
|
||||
loggingConfig
|
||||
concurrencyConfig
|
||||
@@ -131,6 +134,7 @@ type DestroyConfigProvider interface {
|
||||
type TestConfigProvider interface {
|
||||
Args() string
|
||||
|
||||
SkipDeps() bool
|
||||
Timeout() int
|
||||
Cleanup() bool
|
||||
Logs() bool
|
||||
|
||||
@@ -26,6 +26,7 @@ type destroyConfig struct {
|
||||
args string
|
||||
concurrency int
|
||||
interactive bool
|
||||
skipDeps bool
|
||||
logger *zap.SugaredLogger
|
||||
}
|
||||
|
||||
@@ -45,6 +46,10 @@ func (d destroyConfig) Concurrency() int {
|
||||
return d.concurrency
|
||||
}
|
||||
|
||||
func (d destroyConfig) SkipDeps() bool {
|
||||
return d.skipDeps
|
||||
}
|
||||
|
||||
func TestDestroy(t *testing.T) {
|
||||
type testcase struct {
|
||||
helm3 bool
|
||||
|
||||
Reference in New Issue
Block a user