Commit 869efd59 authored by Alexander Nesterenko's avatar Alexander Nesterenko

Fix codestyle and update docs

Signed-off-by: 's avatarAlexander Nesterenko <nestorf250@gmail.com>
parent 8a5c7f15
...@@ -323,7 +323,9 @@ func (i *installCmd) run() error { ...@@ -323,7 +323,9 @@ func (i *installCmd) run() error {
out: i.out, out: i.out,
client: i.client, client: i.client,
} }
if err := deleteSideEffects.run(); err != nil { return err } if err := deleteSideEffects.run(); err != nil {
return err
}
} }
return prettyError(err) return prettyError(err)
} }
......
...@@ -275,9 +275,9 @@ func (u *upgradeCmd) run() error { ...@@ -275,9 +275,9 @@ func (u *upgradeCmd) run() error {
helm.UpgradeWait(u.wait), helm.UpgradeWait(u.wait),
helm.UpgradeDescription(u.description)) helm.UpgradeDescription(u.description))
if err != nil { if err != nil {
fmt.Fprintf(u.out, "UPGRADE FAILED\nROLLING BACK\nError: %v", prettyError(err)) fmt.Fprintf(u.out, "UPGRADE FAILED\nROLLING BACK\nError: %v\n", prettyError(err))
if u.safe { if u.safe {
rollback := &rollbackCmd { rollback := &rollbackCmd{
out: u.out, out: u.out,
client: u.client, client: u.client,
name: u.release, name: u.release,
...@@ -290,9 +290,11 @@ func (u *upgradeCmd) run() error { ...@@ -290,9 +290,11 @@ func (u *upgradeCmd) run() error {
revision: releaseHistory.Releases[0].Version, revision: releaseHistory.Releases[0].Version,
disableHooks: u.disableHooks, disableHooks: u.disableHooks,
} }
if err := rollback.run(); err != nil { return err } if err := rollback.run(); err != nil {
return err
}
} }
return fmt.Errorf("UPGRADE FAILED: %v\n", prettyError(err)) return fmt.Errorf("UPGRADE FAILED: %v", prettyError(err))
} }
if settings.Debug { if settings.Debug {
......
...@@ -96,6 +96,7 @@ helm install [CHART] [flags] ...@@ -96,6 +96,7 @@ helm install [CHART] [flags]
--render-subchart-notes render subchart notes along with the parent --render-subchart-notes render subchart notes along with the parent
--replace re-use the given name, even if that name is already used. This is unsafe in production --replace re-use the given name, even if that name is already used. This is unsafe in production
--repo string chart repository url where to locate the requested chart --repo string chart repository url where to locate the requested chart
--safe if set, upgrade process rolls back changes made in case of failed upgrade
--set stringArray set values on the command line (can specify multiple or separate values with commas: key1=val1,key2=val2) --set stringArray set values on the command line (can specify multiple or separate values with commas: key1=val1,key2=val2)
--set-file stringArray set values from respective files specified via the command line (can specify multiple or separate values with commas: key1=path1,key2=path2) --set-file stringArray set values from respective files specified via the command line (can specify multiple or separate values with commas: key1=path1,key2=path2)
--set-string stringArray set STRING values on the command line (can specify multiple or separate values with commas: key1=val1,key2=val2) --set-string stringArray set STRING values on the command line (can specify multiple or separate values with commas: key1=val1,key2=val2)
...@@ -129,4 +130,4 @@ helm install [CHART] [flags] ...@@ -129,4 +130,4 @@ helm install [CHART] [flags]
* [helm](helm.md) - The Helm package manager for Kubernetes. * [helm](helm.md) - The Helm package manager for Kubernetes.
###### Auto generated by spf13/cobra on 1-Nov-2018 ###### Auto generated by spf13/cobra on 9-Jan-2019
...@@ -83,6 +83,7 @@ helm upgrade [RELEASE] [CHART] [flags] ...@@ -83,6 +83,7 @@ helm upgrade [RELEASE] [CHART] [flags]
--repo string chart repository url where to locate the requested chart --repo string chart repository url where to locate the requested chart
--reset-values when upgrading, reset the values to the ones built into the chart --reset-values when upgrading, reset the values to the ones built into the chart
--reuse-values when upgrading, reuse the last release's values and merge in any overrides from the command line via --set and -f. If '--reset-values' is specified, this is ignored. --reuse-values when upgrading, reuse the last release's values and merge in any overrides from the command line via --set and -f. If '--reset-values' is specified, this is ignored.
--safe if set, upgrade process rolls back changes made in case of failed upgrade
--set stringArray set values on the command line (can specify multiple or separate values with commas: key1=val1,key2=val2) --set stringArray set values on the command line (can specify multiple or separate values with commas: key1=val1,key2=val2)
--set-file stringArray set values from respective files specified via the command line (can specify multiple or separate values with commas: key1=path1,key2=path2) --set-file stringArray set values from respective files specified via the command line (can specify multiple or separate values with commas: key1=path1,key2=path2)
--set-string stringArray set STRING values on the command line (can specify multiple or separate values with commas: key1=val1,key2=val2) --set-string stringArray set STRING values on the command line (can specify multiple or separate values with commas: key1=val1,key2=val2)
...@@ -116,4 +117,4 @@ helm upgrade [RELEASE] [CHART] [flags] ...@@ -116,4 +117,4 @@ helm upgrade [RELEASE] [CHART] [flags]
* [helm](helm.md) - The Helm package manager for Kubernetes. * [helm](helm.md) - The Helm package manager for Kubernetes.
###### Auto generated by spf13/cobra on 1-Nov-2018 ###### Auto generated by spf13/cobra on 9-Jan-2019
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment