Commit 18f900e4 authored by Sushil Kumar's avatar Sushil Kumar

Errors out if install/upgrade fails to load-requirements

Fixes https://github.com/kubernetes/helm/issues/2480
parent d76c1049
...@@ -232,6 +232,8 @@ func (i *installCmd) run() error { ...@@ -232,6 +232,8 @@ func (i *installCmd) run() error {
if err := checkDependencies(chartRequested, req, i.out); err != nil { if err := checkDependencies(chartRequested, req, i.out); err != nil {
return prettyError(err) return prettyError(err)
} }
} else if err != chartutil.ErrRequirementsNotFound {
return fmt.Errorf("cannot load requirements: %v", err)
} }
res, err := i.client.InstallReleaseFromChart( res, err := i.client.InstallReleaseFromChart(
......
...@@ -185,7 +185,11 @@ func (u *upgradeCmd) run() error { ...@@ -185,7 +185,11 @@ func (u *upgradeCmd) run() error {
if err := checkDependencies(ch, req, u.out); err != nil { if err := checkDependencies(ch, req, u.out); err != nil {
return err return err
} }
} else if err != chartutil.ErrRequirementsNotFound {
return fmt.Errorf("cannot load requirements: %v", err)
} }
} else {
return prettyError(err)
} }
resp, err := u.client.UpdateRelease( resp, err := u.client.UpdateRelease(
......
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