neuronaws

package
v0.0.0-...-c891ed9 Latest Latest
Warning

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

Go to latest
Published: Oct 5, 2019 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AwsCommonInput

type AwsCommonInput struct {
	AvailabilityZone string `json:"AvailabilityZone,omitempty"`
}

type CreateNetworkInput

type CreateNetworkInput struct {
	Cidr            string `json:"Cidr,omitempty"`
	Tenancy         string `json:"Tenancy,omitempty"`
	VpcId           string `json:"VpcId,omitempty"`
	SubId           string `json:"SubId,omitempty"`
	IgwId           string `json:"IgwId,omitempty"`
	Zone            string `json:"Zone,omitempty"`
	Name            string `json:"Name,omitempty"`
	DestinationCidr string `json:"DestinationCidr,omitempty"`
	RouteTableId    string `json:"RouteTableId,omitempty"`
}

type CreateServerInput

type CreateServerInput struct {
	ImageId        string   `json:"imageid,omitempty"`
	InstanceType   string   `json:"instancetype,omitempty"`
	KeyName        string   `json:"keyname,omitempty"`
	MaxCount       int64    `json:"maxcount,omitempty"`
	MinCount       int64    `json:"mincount,omitempty"`
	SubnetId       string   `json:"subnetid,omitempty"`
	SecurityGroups []string `json:"securitygroup,omitempty"`
	UserData       string   `json:"userdata,omitempty"`
	AssignPubIp    bool     `json:"assignpubip,omitempty"`
}

type CreateTagsInput

type CreateTagsInput struct {
	Resource string
	Name     string
	Value    string
}

type DeleteComputeInput

type DeleteComputeInput struct {
	ImageId     string   `json:"ImageId,omitempty"`
	SnapshotId  string   `json:"SnapshotId,omitempty"`
	InstanceIds []string `json:"InstanceIds,omitempty"`
}

type DeleteLoadbalancerInput

type DeleteLoadbalancerInput struct {
	LbName      string `json:"lbname,omitempty"`
	LbArn       string `json:"lbarn,omitempty"`
	TargetArn   string `json:"targetarn,omitempty"`
	ListenerArn string `json:"listenerarn,omitempty"`
}

type DescribeComputeInput

type DescribeComputeInput struct {
	InstanceIds []string `json:"instanceids,omitempty"`
	ImageIds    []string `json:"imageids,omitempty"`
	Filters     Filters  `json:"filters,omitempty"`
}

type DescribeLoadbalancersInput

type DescribeLoadbalancersInput struct {
	LbNames     []string `json:"lbname,omitempty"`
	LbArns      []string `json:"lbarn,omitempty"`
	TargetArns  []string `json:"targetarns,omitempty"`
	ListnerArns []string `json:"listnerarns,omitempty"`
}

type DescribeNetworkInput

type DescribeNetworkInput struct {
	SecIds         []string `json:"SecIds,omitempty"`
	IgwIds         []string `json:"IgwId,omitempty"`
	VpcIds         []string `json:"VpcId,omitempty"`
	SubnetIds      []string `json:"SubnetId,omitempty"`
	RouteTableIds  []string `json:"RouteTableIds,omitempty"`
	Filters        Filters  `json:"Filters,omitempty"`
	AssociationsId string   `json:"AssociationsId,omitempty"`
}

type EstablishConnectionInput

type EstablishConnectionInput struct {
	Region   string
	Resource string
	Session  *session.Session
}

func (*EstablishConnectionInput) EstablishConnection

func (con *EstablishConnectionInput) EstablishConnection() (EstablishedSession, error)

type EstablishedSession

type EstablishedSession struct {
	//This will hold the session for all ec2 resource
	Ec2 *ec2.EC2 `json:"Ec2,omitempty"`
	//This will hold the session for all elb(loadbalancer) resource
	Elb *elb.ELB `json:"Elb,omitempty"`
	//This will hold the session for all elb2(loadbalancer version2) resource
	Elb2 *elbv2.ELBV2 `json:"Elb2,omitempty"`
}

func (*EstablishedSession) AttachIgw

func (sess *EstablishedSession) AttachIgw(a *DescribeNetworkInput) error

never pass arrays to attach the intergateways, it never works

func (*EstablishedSession) AttachRouteTable

func (sess *EstablishedSession) AttachRouteTable(r *CreateNetworkInput) error

func (*EstablishedSession) CreateApplicationLb

func (*EstablishedSession) CreateApplicationListners

func (sess *EstablishedSession) CreateApplicationListners(lb *LoadBalanceCreateInput) (*elbv2.CreateListenerOutput, error)

func (*EstablishedSession) CreateClassicLb

func (*EstablishedSession) CreateEgressRule

func (sess *EstablishedSession) CreateEgressRule(i *IngressEgressInput) error

func (*EstablishedSession) CreateIgw

func (*EstablishedSession) CreateImage

func (sess *EstablishedSession) CreateImage(img *ImageCreateInput) (*ec2.CreateImageOutput, error)

I will be responsible for capturing the image of the server when I am called

func (*EstablishedSession) CreateIngressRule

func (sess *EstablishedSession) CreateIngressRule(i *IngressEgressInput) error

func (*EstablishedSession) CreateInstance

func (sess *EstablishedSession) CreateInstance(ins *CreateServerInput) (*ec2.Reservation, error)

func (*EstablishedSession) CreateRouteTable

func (sess *EstablishedSession) CreateRouteTable(r *CreateNetworkInput) (*ec2.CreateRouteTableOutput, error)

func (*EstablishedSession) CreateSecurityGroup

func (sess *EstablishedSession) CreateSecurityGroup(s *CreateNetworkInput) (*ec2.CreateSecurityGroupOutput, error)

func (*EstablishedSession) CreateSubnet

func (*EstablishedSession) CreateTags

func (sess *EstablishedSession) CreateTags(t *CreateTagsInput) error

func (*EstablishedSession) CreateTargetGroups

func (*EstablishedSession) CreateVpc

func (*EstablishedSession) DeleteAppListeners

func (sess *EstablishedSession) DeleteAppListeners(lb *DeleteLoadbalancerInput) error

func (*EstablishedSession) DeleteAppLoadbalancer

func (sess *EstablishedSession) DeleteAppLoadbalancer(lb *DeleteLoadbalancerInput) error

func (*EstablishedSession) DeleteClassicLoadbalancer

func (sess *EstablishedSession) DeleteClassicLoadbalancer(lb *DeleteLoadbalancerInput) error

func (*EstablishedSession) DeleteIgw

func (sess *EstablishedSession) DeleteIgw(i *DescribeNetworkInput) error

func (*EstablishedSession) DeleteInstance

func (*EstablishedSession) DeleteRouteTable

func (sess *EstablishedSession) DeleteRouteTable(r *DescribeNetworkInput) error

func (*EstablishedSession) DeleteSecurityGroup

func (sess *EstablishedSession) DeleteSecurityGroup(s *DescribeNetworkInput) error

func (*EstablishedSession) DeleteSnapshot

func (sess *EstablishedSession) DeleteSnapshot(img *DeleteComputeInput) error

func (*EstablishedSession) DeleteSubnet

func (sess *EstablishedSession) DeleteSubnet(d *DescribeNetworkInput) error

func (*EstablishedSession) DeleteTargetGroup

func (sess *EstablishedSession) DeleteTargetGroup(lb *DeleteLoadbalancerInput) error

func (*EstablishedSession) DeleteVpc

func (sess *EstablishedSession) DeleteVpc(d *DescribeNetworkInput) error

func (*EstablishedSession) DeregisterImage

func (sess *EstablishedSession) DeregisterImage(img *DeleteComputeInput) error

Below function along with DeleteSnapshot has to be used to delete an image.

func (*EstablishedSession) DescribeAllApplicationLoadbalancer

func (sess *EstablishedSession) DescribeAllApplicationLoadbalancer(lb *DescribeLoadbalancersInput) (*elbv2.DescribeLoadBalancersOutput, error)

func (*EstablishedSession) DescribeAllAvailabilityZones

func (sess *EstablishedSession) DescribeAllAvailabilityZones(a *AwsCommonInput) (*ec2.DescribeAvailabilityZonesOutput, error)

func (*EstablishedSession) DescribeAllClassicLoadbalancer

func (sess *EstablishedSession) DescribeAllClassicLoadbalancer(lb *DescribeLoadbalancersInput) (*elb.DescribeLoadBalancersOutput, error)

func (*EstablishedSession) DescribeAllIgw

func (*EstablishedSession) DescribeAllImages

func (sess *EstablishedSession) DescribeAllImages(img *DescribeComputeInput) (*ec2.DescribeImagesOutput, error)

func (*EstablishedSession) DescribeAllInstances

func (sess *EstablishedSession) DescribeAllInstances(des *DescribeComputeInput) (*ec2.DescribeInstancesOutput, error)

func (*EstablishedSession) DescribeAllListners

func (*EstablishedSession) DescribeAllSecurityGroup

func (sess *EstablishedSession) DescribeAllSecurityGroup(d *DescribeNetworkInput) (*ec2.DescribeSecurityGroupsOutput, error)

func (*EstablishedSession) DescribeAllSubnet

func (sess *EstablishedSession) DescribeAllSubnet(d *DescribeNetworkInput) (*ec2.DescribeSubnetsOutput, error)

func (*EstablishedSession) DescribeAllTargetgroups

func (*EstablishedSession) DescribeAllVpc

func (*EstablishedSession) DescribeApplicationLoadbalancer

func (sess *EstablishedSession) DescribeApplicationLoadbalancer(lb *DescribeLoadbalancersInput) (*elbv2.DescribeLoadBalancersOutput, error)

func (*EstablishedSession) DescribeAvailabilityZones

func (sess *EstablishedSession) DescribeAvailabilityZones(a *AwsCommonInput) (*ec2.DescribeAvailabilityZonesOutput, error)

func (*EstablishedSession) DescribeClassicLoadbalancer

func (sess *EstablishedSession) DescribeClassicLoadbalancer(lb *DescribeLoadbalancersInput) (*elb.DescribeLoadBalancersOutput, error)

func (*EstablishedSession) DescribeIgw

func (*EstablishedSession) DescribeImages

func (sess *EstablishedSession) DescribeImages(img *DescribeComputeInput) (*ec2.DescribeImagesOutput, error)

func (*EstablishedSession) DescribeInstance

func (sess *EstablishedSession) DescribeInstance(des *DescribeComputeInput) (*ec2.DescribeInstancesOutput, error)

func (*EstablishedSession) DescribeListners

func (*EstablishedSession) DescribeRouteTable

func (*EstablishedSession) DescribeSecurityGroup

func (*EstablishedSession) DescribeSubnet

func (*EstablishedSession) DescribeTargetgroups

func (*EstablishedSession) DescribeVpc

func (*EstablishedSession) DetachIgw

func (sess *EstablishedSession) DetachIgw(i *DescribeNetworkInput) error

never pass arrays to dettach the intergateways, it never works

func (*EstablishedSession) DettachRouteTable

func (sess *EstablishedSession) DettachRouteTable(r *DescribeNetworkInput) error

func (*EstablishedSession) GetRegions

func (sess *EstablishedSession) GetRegions() (*ec2.DescribeRegionsOutput, error)

func (*EstablishedSession) StartInstances

func (*EstablishedSession) StopInstances

func (*EstablishedSession) WaitTillInstanceAvailable

func (sess *EstablishedSession) WaitTillInstanceAvailable(d *DescribeComputeInput) error

func (*EstablishedSession) WaitTillInstanceRunning

func (sess *EstablishedSession) WaitTillInstanceRunning(d *DescribeComputeInput) error

func (*EstablishedSession) WaitTillInstanceStopped

func (sess *EstablishedSession) WaitTillInstanceStopped(d *DescribeComputeInput) error

func (*EstablishedSession) WaitTillInstanceTerminated

func (sess *EstablishedSession) WaitTillInstanceTerminated(d *DescribeComputeInput) error

func (*EstablishedSession) WaitTillLbDeletionSuccessfull

func (sess *EstablishedSession) WaitTillLbDeletionSuccessfull(lb *DescribeLoadbalancersInput) error

func (*EstablishedSession) WaitTillSubnetAvailable

func (sess *EstablishedSession) WaitTillSubnetAvailable(d *DescribeNetworkInput) error

func (*EstablishedSession) WaitTillVpcAvailable

func (sess *EstablishedSession) WaitTillVpcAvailable(d *DescribeNetworkInput) error

func (*EstablishedSession) WaitUntilIgwDeleted

func (sess *EstablishedSession) WaitUntilIgwDeleted(d *DescribeNetworkInput) (bool, error)

func (*EstablishedSession) WaitUntilRoutTableDeleted

func (sess *EstablishedSession) WaitUntilRoutTableDeleted(d *DescribeNetworkInput) (bool, error)

func (*EstablishedSession) WaitUntilSubnetDeleted

func (sess *EstablishedSession) WaitUntilSubnetDeleted(d *DescribeNetworkInput) (bool, error)

func (*EstablishedSession) WriteRoute

func (sess *EstablishedSession) WriteRoute(r *CreateNetworkInput) error

type Filters

type Filters struct {
	Name  string
	Value []string
}

type ImageCreateInput

type ImageCreateInput struct {
	Description string `json:"Description,omitempty"`
	ServerName  string `json:"ServerName,omitempty"`
	InstanceId  string `json:"InstanceId,omitempty"`
}

type IngressEgressInput

type IngressEgressInput struct {
	Port  int64  `json:"Port,omitempty"`
	SecId string `json:"SecId,omitempty"`
}

type LoadBalanceCreateInput

type LoadBalanceCreateInput struct {
	Name              string   `json:"name,omitempty"`
	VpcId             string   `json:"vpcid,omitempty"`
	Subnets           []string `json:"subnets,omitempty"`
	AvailabilityZones []string
	SecurityGroups    []string `json:"securitygroups,omitempty"`
	Scheme            string   `json:"scheme,omitempty"`
	Type              string   `json:"type,omitempty"`
	SslCert           string   `json:"sslcert,omitempty"` //required only if the LB protocol is HTTPS else can be initiazed with dummy value
	SslPolicy         string   `json:"sslpolicy,omitempty"`
	LbPort            int64    `json:"lbport,omitempty"` //required ex: 8080 or 80 etc
	InstPort          int64    `json:"instport,omitempty"`
	Lbproto           string   `json:"lbproto,omitempty"` //required ex: HTTPS, HTTP
	Instproto         string   `json:"instproto,omitempty"`
	HttpCode          string   `json:"httpcode,omitempty"`
	HealthPath        string   `json:"healthpath,omitempty"`
	IpAddressType     string   `json:"ipaddresstype,omitempty"`
	TargetArn         string   `json:"targetarn,omitempty"`
	LbArn             string   `json:"lbArn,omitempty"`
}

type LoadBalanceResponse

type LoadBalanceResponse struct {
	Name            string                `json:"name,omitempty"`
	Type            string                `json:"type,omitempty"`
	LbDns           string                `json:"lbdns,omitempty"`
	LbArn           string                `json:"lbarn,omitempty"`
	TargetArn       string                `json:"targetarn,omitempty"`
	ListnerArn      string                `json:"listnerarn,omitempty"`
	Createdon       string                `json:"createdon,omitempty"`
	VpcId           string                `json:"vpcid,omitempty"`
	Scheme          string                `json:"scheme,omitempty"`
	DefaultResponse interface{}           `json:"defaultresponse,omitempty"`
	LbDeleteStatus  string                `json:"lbdeletestatus,omitempty"`
	ApplicationLb   []LoadBalanceResponse `json:"applicationlb,omitempty"`
	ClassicLb       []LoadBalanceResponse `json:"classiclb,omitempty"`
}

type UpdateComputeInput

type UpdateComputeInput struct {
	InstanceIds []string `json:"instanceids,omitempty"`
	Force       string   `json:"force,omitempty"`
}

Jump to

Keyboard shortcuts

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