jx: github.com/jenkins-x/jx/pkg/cloud/amazon Index | Files | Directories

package amazon

import "github.com/jenkins-x/jx/pkg/cloud/amazon"

Index

Package Files

cli.go common.go ecr.go eks.go routes.go s3.go zones.go

Constants

const DefaultRegion = "us-west-2"

func AvailabilityZones Uses

func AvailabilityZones() ([]string, error)

func CleanUpObsoleteEksClusterStack Uses

func CleanUpObsoleteEksClusterStack(clusterName string, profile string, region string) error

CleanUpObsoleteEksClusterStack removes dead eksctl CloudFormation stack associated with given EKS cluster name.

func CreateS3Bucket Uses

func CreateS3Bucket(bucketName string, profile string, region string) (string, error)

CreateS3Bucket creates a new S3 bucket in the default region with the given bucket name returning the location string

func EksClusterExists Uses

func EksClusterExists(clusterName string, profile string, region string) (bool, error)

EksClusterExists checks if EKS cluster with given name exists in given region.

func EksClusterObsoleteStackExists Uses

func EksClusterObsoleteStackExists(clusterName string, profile string, region string) (bool, error)

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.

func EksctlStackName Uses

func EksctlStackName(clusterName string) string

EksctlStackName generates CloudFormation stack name for given EKS cluster name. This function follows eksctl naming convention.

func GetAccountIDAndRegion Uses

func GetAccountIDAndRegion(profile string, region string) (string, string, error)

GetAccountIDAndRegion returns the current account ID and region

func GetContainerRegistryHost Uses

func GetContainerRegistryHost() (string, error)

GetContainerRegistryHost

func GetRegionFromContainerRegistryHost Uses

func GetRegionFromContainerRegistryHost(kubeClient kubernetes.Interface, namespace string, dockerRegistry string) string

Deprecated!

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.

func InstallAwsIamAuthenticator Uses

func InstallAwsIamAuthenticator(skipPathScan bool) error

InstallAwsIamAuthenticator install iam authenticator for AWS

func InstallAwsIamAuthenticatorWithVersion Uses

func InstallAwsIamAuthenticatorWithVersion(version string, skipPathScan bool) error

InstallAwsIamAuthenticatorWithVersion install a specific version of iam authenticator for AWS

func InstallEksCtl Uses

func InstallEksCtl(skipPathScan bool) error

InstallEksCtl installs eks cli

func InstallEksCtlWithVersion Uses

func InstallEksCtlWithVersion(version string, skipPathScan bool) error

InstallEksCtlWithVersion install a specific version of eks cli

func InstallKops Uses

func InstallKops() error

InstallKops installs kops

func LazyCreateRegistry Uses

func LazyCreateRegistry(kube kubernetes.Interface, namespace string, region string, dockerRegistry string, orgName string, appName string) error

LazyCreateRegistry lazily creates the ECR registry if it does not already exist

func NewAwsSession Uses

func NewAwsSession(profileOption string, regionOption string) (*session.Session, error)

func NewAwsSessionWithoutOptions Uses

func NewAwsSessionWithoutOptions() (*session.Session, error)

func RegisterAwsCustomDomain Uses

func RegisterAwsCustomDomain(customDomain string, elbAddress string) error

RegisterAwsCustomDomain registers a wildcard ALIAS for the custom domain to point at the given ELB host name

func ResolveRegion Uses

func ResolveRegion(profileOption string, regionOption string) (string, error)

func ResolveRegionWithoutOptions Uses

func ResolveRegionWithoutOptions() (string, error)

func UserHomeDir Uses

func UserHomeDir() string

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. :-|

Directories

PathSynopsis
storage
vault

Package amazon imports 24 packages (graph) and is imported by 8 packages. Updated 2019-09-11. Refresh now. Tools for package owners.