const DefaultRegion = "us-west-2"
CleanUpObsoleteEksClusterStack removes dead eksctl CloudFormation stack associated with given EKS cluster name.
CreateS3Bucket creates a new S3 bucket in the default region with the given bucket name returning the location string
EksClusterExists checks if EKS cluster with given name exists in given region.
EksClusterObsoleteStackExists detects if there is obsolete CloudFormation stack for given EKS cluster.
If EKS cluster creation process is interrupted, there will be CloudFormation stack in ROLLBACK_COMPLETE state left. Such dead stack prevents eksctl from creating cluster with the same name. This is common activity then to remove stacks like this and this function performs this action.
EksctlStackName generates CloudFormation stack name for given EKS cluster name. This function follows eksctl naming convention.
GetAccountIDAndRegion returns the current account ID and region
func GetRegionFromContainerRegistryHost(kubeClient kubernetes.Interface, namespace string, dockerRegistry string) string
This function is kept for backwards compatibility. AWS region should not be resolved from ECR address, but read from ConfigMap (see RememberRegion function). To keep backwards compatibility with existing installations this function will be kept for a while and it will perform migration to config map. Eventually it will be removed from a codebase.
InstallAwsIamAuthenticator install iam authenticator for AWS
InstallAwsIamAuthenticatorWithVersion install a specific version of iam authenticator for AWS
InstallEksCtl installs eks cli
InstallEksCtlWithVersion install a specific version of eks cli
InstallKops installs kops
LazyCreateRegistry lazily creates the ECR registry if it does not already exist
RegisterAwsCustomDomain registers a wildcard ALIAS for the custom domain to point at the given ELB host name
UserHomeDir returns the home directory for the user the process is running under. This is a copy of shareddefaults.UserHomeDir in the internal AWS package. We can't user user.Current().HomeDir as we want to override this during testing. :-|