Documentation ¶
Overview ¶
Package utils ...
Index ¶
Constants ¶
View Source
const ( // MaxRetries ... MaxRetries int = 4 // RetryInterval in seconds RetryInterval int = 15 // IBMCLOUD_AUTHTYPE ... IBMCLOUD_AUTHTYPE = "IBMCLOUD_AUTHTYPE" // IBMCLOUD_APIKEY ... IBMCLOUD_APIKEY = "IBMCLOUD_APIKEY" // IBMCLOUD_PROFILEID ... IBMCLOUD_PROFILEID = "IBMCLOUD_PROFILEID" // IAM ... IAM = "iam" // PODIDENTITY ... PODIDENTITY = "pod-identity" // DEFAULT ... DEFAULT = "DEFAULT" // IBMCLOUD_CREDENTIALS_SECRET ... IBMCLOUD_CREDENTIALS_SECRET = "ibm-cloud-credentials" // STORAGE_SECRET_STORE_SECRET ... STORAGE_SECRET_STORE_SECRET = "storage-secret-store" // CLOUD_PROVIDER_ENV ... CLOUD_PROVIDER_ENV = "ibm-credentials.env" // SECRET_STORE_FILE ... SECRET_STORE_FILE = "slclient.toml" // StagePrivateIAMURL ... StagePrivateIAMURL = "https://private.iam.test.cloud.ibm.com" // ProdPrivateIAMURL ... ProdPrivateIAMURL = "https://private.iam.cloud.ibm.com" // PublicIAMURL ... ProdPublicIAMURL = "https://iam.cloud.ibm.com" // StagePublicIAMURL ... StagePublicIAMURL = "https://iam.test.cloud.ibm.com" // VPC ... VPC = "vpc" // Bluemix ... Bluemix = "bluemix" // Softlayer ... Softlayer = "softlayer" // SatelliteProvider ... SatelliteProvider = "upi" // VPCGen2 refers to VPC cluster type ... VPCGen2 = "vpc-gen2_cruiser" // Cruiser refers to the Classic cluster type ... Cruiser = "cruiser" // SatelliteCruiser refers to satellite cluster type ... SatelliteCruiser = "satellite_cruiser" )
View Source
const ( // ErrCredentialsUndefined ... ErrCredentialsUndefined = "ibmcloud credentials undefined" // ErrInvalidCredentialsFormat ... ErrInvalidCredentialsFormat = "ibmcloud credentials are provided in invalid format, unable to parse the credentials" // ErrAuthTypeUndefined ... ErrAuthTypeUndefined = "IBMCLOUD_AUTHTYPE undefined, expected - IAM or PODIDENTITY" // ErrUnknownCredentialType ... ErrUnknownCredentialType = "Unknown IBMCLOUD_AUTHTYPE provided. IBMCLOUD_AUTHTYPE: %s" // ErrAPIKeyNotProvided ... ErrAPIKeyNotProvided = "API key is not provided" // ErrProfileIDNotProvided ... ErrProfileIDNotProvided = "Profile ID is not provided" // APIKeyNotFound ... APIKeyNotFound = "api key could not be found" // UserNotFound ... UserNotFound = "user not found or active" // ProfileNotFound ... ProfileNotFound = "selected trusted profile not eligible for cr token" // ErrSecretConfigPathUndefined ... ErrSecretConfigPathUndefined = "SECRET_CONFIG_PATH is not defined" // ErrEmptyTokenResponse ... ErrEmptyTokenResponse = "Empty token response received" // ErrFetchingClusterConfig ... ErrFetchingClusterConfig = "Error fetching cluster config" // ErrFetchingK8sClient ... ErrFetchingK8sClient = "Error fetching k8s client" // ErrFetchingNamespace ... ErrFetchingNamespace = "Unable to read k8s namespace" // ErrFetchingSecrets ... ErrFetchingSecrets = "Error fetching secrets" // ErrEmptyDataInSecret ... ErrEmptyDataInSecret = "No data found in the secret %s" // ErrExpectedDataNotFound ... ErrExpectedDataNotFound = "Expected data %s not found in the secret %s" // ErrFetchingSecretData ... ErrFetchingSecretData = "Unable to fetch data from secret, Secret: %s, Data: %s" // ErrParsingConfig ... ErrParsingConfig = "Failed to parse storage secret store config" // ErrFetchingENV ... ErrFetchingENV = "Failed to gather environment variables" // ErrEmptyClusterConfig ... ErrEmptyClusterConfig = "Cluster config is empty" // ErrFetchingK8sClusterConfig ... ErrFetchingK8sClusterConfig = "Error fetching k8s cluster config" // WarnFetchingTokenExchangeURL ... WarnFetchingTokenExchangeURL = "Token exchange url not found in the secret" // ErrInvalidProviderType ... ErrInvalidProviderType = "Invalid provider type. Valid options are - vpc, bluemix, softlayer" // ErrEmptyConfigMapData ... ErrEmptyConfigMapData = "Unable to find %s key in %s config map" )
Variables ¶
View Source
var ( // TokenExpirydiff ... TokenExpirydiff uint64 )
Functions ¶
This section is empty.
Types ¶
Click to show internal directories.
Click to hide internal directories.