util

package
v2.21.15 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 14, 2023 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CleanUpHelmTempDir

func CleanUpHelmTempDir(cacheDir string, logger *zap.SugaredLogger)

CleanUpHelmTempDir removes the helm cache directory. If deletion fails error is looged using the logger.

func CreateHelmTempDir

func CreateHelmTempDir(cacheDir string) (string, error)

CreateHelmTempDir creates a temporary directory inside cacheDir where helm caches will be download.

func GetCredentialFromSecret

func GetCredentialFromSecret(ctx context.Context, client ctrlruntimeclient.Client, namespce string, name string, key string) (string, error)

GetCredentialFromSecret get the secret and returns secret.Data[key].

func HelmAuthFromCredentials

func HelmAuthFromCredentials(ctx context.Context, client ctrlruntimeclient.Client, registryConfigFilePath string, secretNamespace string, source *appskubermaticv1.HelmSource) (helmclient.AuthSettings, error)

HelmAuthFromCredentials builds helmclient.AuthSettings from source.Credentials. registryConfigFilePath is the path of the file that stores credentials for OCI registry.

Types

type StatusUpdater

type StatusUpdater func(status *appskubermaticv1.ApplicationInstallationStatus)

StatusUpdater is a function that postpone the update of the applicationInstallation. It used to set status's filed of a specific template Provider (eg status.HelmRelease).

var NoStatusUpdate StatusUpdater = func(status *appskubermaticv1.ApplicationInstallationStatus) {

}

NoStatusUpdate is a StatusUpdater that does not update the status. It useful in case an error happens and we don't have information to update the status.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL