Documentation ¶
Index ¶
Constants ¶
View Source
const ( DefaultCloudProviderConfigSecName = "azure-cloud-provider" DefaultCloudProviderConfigSecNamespace = "kube-system" DefaultCloudProviderConfigSecKey = "cloud-config" )
cloud provider config secret
Variables ¶
View Source
var ( ErrNoKubeClient = errors.New("no kube client provided") ErrNoData = errors.New("no data in secret") )
Functions ¶
func Load ¶
func Load[Type any](ctx context.Context, secretLoaderConfig *K8sSecretLoaderConfig, fileLoaderConfig *FileLoaderConfig) (*Type, error)
Types ¶
type CloudConfigType ¶
type CloudConfigType string
The config type for Azure cloud provider secret. Supported values are: * file : The values are read from local cloud-config file. * secret : The values from secret would override all configures from local cloud-config file. * merge : The values from secret would override only configurations that are explicitly set in the secret. This is the default value.
const ( CloudConfigTypeFile CloudConfigType = "file" CloudConfigTypeSecret CloudConfigType = "secret" CloudConfigTypeMerge CloudConfigType = "merge" )
type ConfigMergeConfig ¶
type ConfigMergeConfig struct { // The cloud configure type for Azure cloud provider. Supported values are file, secret and merge. CloudConfigType CloudConfigType `json:"cloudConfigType,omitempty" yaml:"cloudConfigType,omitempty"` }
type FileLoader ¶
type FileLoader[Type any] struct { // contains filtered or unexported fields }
type FileLoaderConfig ¶
type FileLoaderConfig struct {
FilePath string
}
type K8sSecretConfig ¶
type K8sSecretLoaderConfig ¶
type K8sSecretLoaderConfig struct { K8sSecretConfig KubeClient clientset.Interface }
Click to show internal directories.
Click to hide internal directories.