aws

package
v0.0.0-...-264ff9f Latest Latest
Warning

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

Go to latest
Published: Mar 4, 2018 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateKeypair

func CreateKeypair(ec2Svc *ec2.EC2, name string) (*ec2.CreateKeyPairOutput, error)

func CreateSession

func CreateSession(awsProfile *AWSProfile, region string) (*session.Session, error)

Types

type AWSCluster

type AWSCluster struct {
	Region            string
	AWSProfile        *AWSProfile
	Name              string
	KeyPair           *ec2.CreateKeyPairOutput
	SecurityGroupId   string
	SubnetId          string
	InternetGatewayId string
	NodeInfos         map[int]*NodeInfo
	InstanceIds       []*string
	VpcId             string
}

AWSCluster stores the data of a aws backed cluster

func NewAWSCluster

func NewAWSCluster(name string, region string) *AWSCluster

func (AWSCluster) GetClusterType

func (awsCluster AWSCluster) GetClusterType() string

func (AWSCluster) GetKeyMaterial

func (awsCluster AWSCluster) GetKeyMaterial() string

func (*AWSCluster) KeyName

func (awsCluster *AWSCluster) KeyName() string

KeyName return a key name according to the Deployment.Name with suffix "-key"

func (*AWSCluster) PolicyName

func (awsCluster *AWSCluster) PolicyName() string

PolicyName return a key name according to the Deployment.Name with suffix "-policy"

func (*AWSCluster) ReloadKeyPair

func (awsCluster *AWSCluster) ReloadKeyPair(keyMaterial string) error

ReloadKeyPair reload KeyPair by keyName

func (*AWSCluster) RoleName

func (awsCluster *AWSCluster) RoleName() string

RoleName return a key name according to the Name with suffix "-role"

func (AWSCluster) SshConfig

func (awsCluster AWSCluster) SshConfig(user string) (*ssh.ClientConfig, error)

func (*AWSCluster) StackName

func (awsCluster *AWSCluster) StackName() string

func (AWSCluster) SubnetName

func (awsCluster AWSCluster) SubnetName() string

SubnetName return a key name according to the Name with suffix "-vpc"

func (AWSCluster) VPCName

func (awsCluster AWSCluster) VPCName() string

VPCName return a key name according to the Name with suffix "-vpc"

type AWSProfile

type AWSProfile struct {
	UserId    string
	AwsId     string
	AwsSecret string
}

type NodeInfo

type NodeInfo struct {
	Instance      *ec2.Instance
	Arn           string
	PublicDnsName string
	PrivateIp     string
}

Jump to

Keyboard shortcuts

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