mirror of
https://github.com/helm/helm.git
synced 2026-05-28 04:35:48 -04:00
Fix reachability check which must be disabled for helm template (unless --validate is specified)
Signed-off-by: Andreas Sommer <andreas.sommer87@googlemail.com>
This commit is contained in:
parent
2c87d89a80
commit
3a843df1ff
1 changed files with 5 additions and 2 deletions
|
|
@ -147,8 +147,11 @@ func (i *Install) installCRDs(crds []*chart.File) error {
|
|||
//
|
||||
// If DryRun is set to true, this will prepare the release, but not install it
|
||||
func (i *Install) Run(chrt *chart.Chart, vals map[string]interface{}) (*release.Release, error) {
|
||||
if err := i.cfg.KubeClient.IsReachable(); err != nil {
|
||||
return nil, err
|
||||
// Check reachability of cluster unless in client-only mode (e.g. `helm template` without `--validate`)
|
||||
if !i.ClientOnly {
|
||||
if err := i.cfg.KubeClient.IsReachable(); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
}
|
||||
|
||||
if err := i.availableName(); err != nil {
|
||||
|
|
|
|||
Loading…
Reference in a new issue