Skip to content

Commit

Permalink
fix: backport helm#6361 fix to Helm 2
Browse files Browse the repository at this point in the history
  • Loading branch information
Ewocker committed Jul 6, 2020
1 parent 80c4bb4 commit bd29d2b
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions pkg/tiller/release_server.go
Original file line number Diff line number Diff line change
Expand Up @@ -270,7 +270,9 @@ func capabilities(disc discovery.DiscoveryInterface) (*chartutil.Capabilities, e
// TODO(mattfarina): In Helm v3 merge with GetVersionSet
func GetAllVersionSet(client discovery.ServerResourcesInterface) (chartutil.VersionSet, error) {
groups, resources, err := client.ServerGroupsAndResources()
if err != nil {
// It is okay to silently swallow a GroupDiscoveryFailedError, which is actually just
// a warning. The 'groups' will still have all of the valid data.
if err != nil && !discovery.IsGroupDiscoveryFailedError(err) {
return chartutil.DefaultVersionSet, err
}

Expand Down Expand Up @@ -318,7 +320,9 @@ func GetAllVersionSet(client discovery.ServerResourcesInterface) (chartutil.Vers
// GetVersionSet retrieves a set of available k8s API versions
func GetVersionSet(client discovery.ServerGroupsInterface) (chartutil.VersionSet, error) {
groups, err := client.ServerGroups()
if err != nil {
// It is okay to silently swallow a GroupDiscoveryFailedError, which is actually just
// a warning. The 'groups' will still have all of the valid data.
if err != nil && !discovery.IsGroupDiscoveryFailedError(err) {
return chartutil.DefaultVersionSet, err
}

Expand Down

0 comments on commit bd29d2b

Please sign in to comment.