Documentation
¶
Index ¶
- func ChartsFromIndex(contents []byte, r *models.AppRepository, shallow bool) ([]models.Chart, error)
- func InitHTTPClient(appRepo *v1alpha1.AppRepository, caCertSecret *corev1.Secret) (*http.Client, error)
- func InitNetClient(appRepo *v1alpha1.AppRepository, caCertSecret, authSecret *corev1.Secret, ...) (*http.Client, error)
- func SecretNameForNamespacedRepo(repoName, namespace string) string
- func SecretNameForRepo(repoName string) string
- type ChartPuller
- type OCIPuller
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ChartsFromIndex ¶
func ChartsFromIndex(contents []byte, r *models.AppRepository, shallow bool) ([]models.Chart, error)
ChartsFromIndex receives an array of bytes containing the contents of index.yaml from a helm repo and returns all Chart models from that index. The shallow flag controls whether only the latest version of the charts is returned or all versions
func InitHTTPClient ¶
func InitHTTPClient(appRepo *v1alpha1.AppRepository, caCertSecret *corev1.Secret) (*http.Client, error)
InitHTTPClient returns an HTTP client using the configuration from the apprepo and CA secret given.
func InitNetClient ¶
func InitNetClient(appRepo *v1alpha1.AppRepository, caCertSecret, authSecret *corev1.Secret, defaultHeaders http.Header) (*http.Client, error)
InitNetClient returns an HTTP client based on the chart details loading a custom CA if provided (as a secret)
func SecretNameForNamespacedRepo ¶
SecretNameForNamespacedRepo returns a name suitable for recording a copy of a per-namespace repository secret in the kubeapps namespace.
func SecretNameForRepo ¶
SecretNameForRepo returns the name of a secret for an apprepo
Types ¶
type ChartPuller ¶
ChartPuller interface to pull a chart from an OCI registry
type OCIPuller ¶
OCIPuller implements ChartPuller
func (*OCIPuller) PullOCIChart ¶
Code from Helm Registry Client. Copied here since it belonged to a internal package. TODO(agamez): Some adaptations on the Kubeapps/Helm side are still required to be fully able to use the Helm code a library instead More information: // https://github.com/helm/helm/issues/10623 // https://github.com/vmware-tanzu/kubeapps/pull/4154
This function has been slightly adapted from: https://github.com/helm/helm/blob/v3.8.0/pkg/registry/client.go#L249