Skip to content

Commit

Permalink
Merge pull request #288 from tuxtof/feat/reset-and-reuse
Browse files Browse the repository at this point in the history
✨ expose resetThenReuseValues upgrade option
  • Loading branch information
k8s-ci-robot authored Oct 3, 2024
2 parents 88be5a6 + c343bee commit 8241bfd
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 0 deletions.
4 changes: 4 additions & 0 deletions api/v1alpha1/helmchartproxy_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,10 @@ type HelmUpgradeOptions struct {
// +optional
ReuseValues bool `json:"reuseValues,omitempty"`

// ResetThenReuseValues will reset the values to the chart's built-ins then merge with user's last supplied values.
// +optional
ResetThenReuseValues bool `json:"resetThenReuseValues,omitempty"`

// Recreate will (if true) recreate pods after a rollback.
// +optional
Recreate bool `json:"recreate,omitempty"`
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -236,6 +236,11 @@ spec:
description: Recreate will (if true) recreate pods after a
rollback.
type: boolean
resetThenReuseValues:
description: ResetThenReuseValues will reset the values to
the chart's built-ins then merge with user's last supplied
values.
type: boolean
resetValues:
description: ResetValues will reset the values to the chart's
built-ins rather than merging with existing.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -243,6 +243,11 @@ spec:
description: Recreate will (if true) recreate pods after a
rollback.
type: boolean
resetThenReuseValues:
description: ResetThenReuseValues will reset the values to
the chart's built-ins then merge with user's last supplied
values.
type: boolean
resetValues:
description: ResetValues will reset the values to the chart's
built-ins rather than merging with existing.
Expand Down
1 change: 1 addition & 0 deletions internal/helm_client.go
Original file line number Diff line number Diff line change
Expand Up @@ -162,6 +162,7 @@ func generateHelmUpgradeConfig(actionConfig *helmAction.Configuration, helmOptio
upgradeClient.Force = helmOptions.Upgrade.Force
upgradeClient.ResetValues = helmOptions.Upgrade.ResetValues
upgradeClient.ReuseValues = helmOptions.Upgrade.ReuseValues
upgradeClient.ResetThenReuseValues = helmOptions.Upgrade.ResetThenReuseValues
upgradeClient.MaxHistory = helmOptions.Upgrade.MaxHistory
upgradeClient.CleanupOnFail = helmOptions.Upgrade.CleanupOnFail

Expand Down

0 comments on commit 8241bfd

Please sign in to comment.