Add the SyncArgs option and --sync-args flag (#1375)

* add the SyncArgs option

Signed-off-by: Tim Ramlot <42113979+inteon@users.noreply.github.com>

* add syncArgs to helmDefaults and update index.md

Signed-off-by: Tim Ramlot <42113979+inteon@users.noreply.github.com>

* add --sync-args flags to helmfile sync

Signed-off-by: Tim Ramlot <42113979+inteon@users.noreply.github.com>

* add tests for appendExtraDiffFlags and appendExtraSyncFlags

Signed-off-by: Tim Ramlot <42113979+inteon@users.noreply.github.com>

---------

Signed-off-by: Tim Ramlot <42113979+inteon@users.noreply.github.com>
This commit is contained in:
Tim Ramlot
2024-02-29 20:49:48 +08:00
committed by GitHub
parent dc2ccd6e67
commit 7ccacb7ee5
10 changed files with 141 additions and 0 deletions
+7
View File
@@ -64,6 +64,8 @@ type ApplyOptions struct {
Cascade string
// SuppressOutputLineRegex is a list of regexes to suppress output lines
SuppressOutputLineRegex []string
// SyncArgs is the list of arguments to pass to helm upgrade.
SyncArgs string
}
// NewApply creates a new Apply
@@ -240,3 +242,8 @@ func (a *ApplyImpl) Cascade() string {
func (a *ApplyImpl) SuppressOutputLineRegex() []string {
return a.ApplyOptions.SuppressOutputLineRegex
}
// SyncArgs returns the SyncArgs.
func (a *ApplyImpl) SyncArgs() string {
return a.ApplyOptions.SyncArgs
}
+7
View File
@@ -32,6 +32,8 @@ type SyncOptions struct {
PostRendererArgs []string
// Cascade '--cascade' to helmv3 delete, available values: background, foreground, or orphan, default: background
Cascade string
// SyncArgs is the list of arguments to pass to the helm upgrade command.
SyncArgs string
}
// NewSyncOptions creates a new Apply
@@ -132,3 +134,8 @@ func (t *SyncImpl) PostRendererArgs() []string {
func (t *SyncImpl) Cascade() string {
return t.SyncOptions.Cascade
}
// SyncArgs returns the sync args
func (t *SyncImpl) SyncArgs() string {
return t.SyncOptions.SyncArgs
}