Fix ks-core helm chart (#5101)

This commit is contained in:
hongming
2022-07-27 18:31:53 +08:00
committed by GitHub
parent 1f2f6157d7
commit 965dbb5ca7
3 changed files with 239 additions and 2 deletions

View File

@@ -401,7 +401,11 @@ func waitForCacheSync(discoveryClient discovery.DiscoveryInterface, sharedInform
return err
})
if err != nil {
return fmt.Errorf("failed to fetch group version resources %s: %s", groupVersion, err)
if errors.IsNotFound(err) {
klog.Warningf("group version %s not exists in the cluster", groupVersion)
return nil
}
return fmt.Errorf("failed to fetch group version %s: %s", groupVersion, err)
}
for _, resourceName := range resourceNames {
groupVersionResource := groupVersion.WithResource(resourceName)