provider

package
v0.7.0 Latest Latest
Warning

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

Go to latest
Published: May 20, 2022 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// DefaultName is the name of Provider object
	DefaultName = "default"
	// DefaultNamespace is the namespace of Provider object
	DefaultNamespace = "default"
)
View Source
const (
	ErrCredentialNotRetrieved = "Credentials are not retrieved from referenced Provider"
)

Variables

This section is empty.

Functions

func GetProviderCredentials

func GetProviderCredentials(ctx context.Context, k8sClient client.Client, provider *v1beta1.Provider, region string) (map[string]string, error)

GetProviderCredentials gets provider credentials by cloud provider name

func GetProviderFromConfiguration

func GetProviderFromConfiguration(ctx context.Context, k8sClient client.Client, namespace, name string) (*v1beta1.Provider, error)

GetProviderFromConfiguration gets provider object from Configuration Returns: 1) (nil, err): hit an issue to find the provider 2) (nil, nil): provider not found 3) (provider, nil): provider found

Types

type AWSCredentials

type AWSCredentials struct {
	AWSAccessKeyID     string `yaml:"awsAccessKeyID"`
	AWSSecretAccessKey string `yaml:"awsSecretAccessKey"`
	AWSSessionToken    string `yaml:"awsSessionToken"`
}

AWSCredentials are credentials for AWS

type AlibabaCloudCredentials

type AlibabaCloudCredentials struct {
	AccessKeyID     string `yaml:"accessKeyID"`
	AccessKeySecret string `yaml:"accessKeySecret"`
	SecurityToken   string `yaml:"securityToken"`
}

AlibabaCloudCredentials are credentials for Alibaba Cloud

type AzureCredentials

type AzureCredentials struct {
	ARMClientID       string `yaml:"armClientID"`
	ARMClientSecret   string `yaml:"armClientSecret"`
	ARMSubscriptionID string `yaml:"armSubscriptionID"`
	ARMTenantID       string `yaml:"armTenantID"`
}

AzureCredentials are credentials for Azure

type BaiduCloudCredentials added in v0.3.5

type BaiduCloudCredentials struct {
	KeyBaiduAccessKey string `yaml:"accessKey"`
	KeyBaiduSecretKey string `yaml:"secretKey"`
}

BaiduCloudCredentials are credentials for Baidu Cloud

type CloudProvider

type CloudProvider string

CloudProvider is a type for mark a Cloud Provider

type CustomCredentials added in v0.3.1

type CustomCredentials map[string]string

CustomCredentials are credentials for custom (you self)

type ECCredentials

type ECCredentials struct {
	ECApiKey string `yaml:"ecApiKey"`
}

ECCredentials are credentials for Elastic CLoud

type GCPCredentials

type GCPCredentials struct {
	GCPCredentialsJSON string `yaml:"gcpCredentialsJSON"`
	GCPProject         string `yaml:"gcpProject"`
}

GCPCredentials are credentials for GCP

type HuaWeiCloudCredentials added in v0.6.0

type HuaWeiCloudCredentials struct {
	AccessKey string `yaml:"accessKey"`
	SecretKey string `yaml:"secretKey"`
}

HuaWeiCloudCredentials are credentials for Huawei Cloud

type TencentCloudCredentials added in v0.3.3

type TencentCloudCredentials struct {
	SecretID  string `yaml:"secretID"`
	SecretKey string `yaml:"secretKey"`
}

TencentCloudCredentials are credentials for Tencent Cloud

type UCloudCredentials

type UCloudCredentials struct {
	PublicKey  string `yaml:"publicKey"`
	PrivateKey string `yaml:"privateKey"`
	Region     string `yaml:"region"`
	ProjectID  string `yaml:"projectID"`
}

UCloudCredentials are credentials for UCloud

type VSphereCredentials

type VSphereCredentials struct {
	VSphereUser               string `yaml:"vSphereUser"`
	VSpherePassword           string `yaml:"vSpherePassword"`
	VSphereServer             string `yaml:"vSphereServer"`
	VSphereAllowUnverifiedSSL string `yaml:"vSphereAllowUnverifiedSSL,omitempty"`
}

VSphereCredentials are credentials for VSphere

Jump to

Keyboard shortcuts

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