Documentation
¶
Index ¶
- Constants
- func NewPlatform() platform.Platform
- type AwsEc2Address
- type AwsEc2AddressList
- type AwsEc2BlockDeviceMapping
- type AwsEc2Ebs
- type AwsEc2Gateway
- type AwsEc2GatewayAttachent
- type AwsEc2GatewayCreateResult
- type AwsEc2GatewayList
- type AwsEc2Image
- type AwsEc2ImageList
- type AwsEc2Instance
- type AwsEc2Instances
- type AwsEc2IpAddrPublicIpAssociation
- type AwsEc2IpAddress
- type AwsEc2NatGateway
- type AwsEc2NatGatewayCreateResult
- type AwsEc2NatGatewayList
- type AwsEc2NetworkInterface
- type AwsEc2NetworkInterfaceCreateResult
- type AwsEc2NetworkInterfaceCreateSpec
- type AwsEc2NetworkInterfaceList
- type AwsEc2Platform
- func (a *AwsEc2Platform) ActiveChanged(ctx context.Context, platformActive bool) error
- func (a *AwsEc2Platform) AddImageIfNotPresent(ctx context.Context, imageInfo *infracommon.ImageInfo, ...) error
- func (a *AwsEc2Platform) AllocateElasticIP(ctx context.Context) (string, error)
- func (a *AwsEc2Platform) AllowIntraVpcTraffic(ctx context.Context, groupId string) error
- func (a *AwsEc2Platform) AssignFreePrecreatedSubnet(ctx context.Context, subnetId, vmGroupName, newName string) error
- func (a *AwsEc2Platform) AttachPortToServer(ctx context.Context, serverName string, subnetNames vmlayer.SubnetNames, ...) error
- func (a *AwsEc2Platform) CheckServerReady(ctx context.Context, client ssh.Client, serverName string) error
- func (a *AwsEc2Platform) ConfigureCloudletSecurityRules(ctx context.Context, egressRestricted bool, TrustPolicy *edgeproto.TrustPolicy, ...) error
- func (a *AwsEc2Platform) ConfigureTrustPolicyExceptionSecurityRules(ctx context.Context, TrustPolicyException *edgeproto.TrustPolicyException, ...) error
- func (a *AwsEc2Platform) CreateImageFromUrl(ctx context.Context, imageName, imageUrl, md5Sum string) error
- func (a *AwsEc2Platform) CreateInternalRouteTable(ctx context.Context, vpcId, natGwId, name string) (string, error)
- func (a *AwsEc2Platform) CreateInternetGateway(ctx context.Context, vpcName string) (*AwsEc2Gateway, error)
- func (a *AwsEc2Platform) CreateInternetGatewayDefaultRoute(ctx context.Context, vpcName, vpcId string) error
- func (a *AwsEc2Platform) CreateNatGateway(ctx context.Context, subnetId, elasticIpId, vpcName string) (string, error)
- func (a *AwsEc2Platform) CreateSecurityGroup(ctx context.Context, secGrpname, vpcId, vmGroupName string) (*AwsEc2SecGrp, error)
- func (a *AwsEc2Platform) CreateSecurityGroupRule(ctx context.Context, groupId, protocol, portRange, allowedCIDR string) error
- func (a *AwsEc2Platform) CreateSubnet(ctx context.Context, vmGroupName, name string, cidr string, ...) (string, error)
- func (a *AwsEc2Platform) CreateVM(ctx context.Context, groupName string, vm *vmlayer.VMOrchestrationParams, ...) error
- func (a *AwsEc2Platform) CreateVMs(ctx context.Context, vmgp *vmlayer.VMGroupOrchestrationParams, ...) error
- func (a *AwsEc2Platform) CreateVPC(ctx context.Context, name string, cidr string) (string, error)
- func (a *AwsEc2Platform) DeleteAllResourcesForGroup(ctx context.Context, vmGroupName, ownerID string) error
- func (a *AwsEc2Platform) DeleteImage(ctx context.Context, folder, imageName string) error
- func (a *AwsEc2Platform) DeleteInstances(ctx context.Context, instancesIds []string) error
- func (a *AwsEc2Platform) DeleteSecurityGroup(ctx context.Context, groupId, vpcId string) error
- func (a *AwsEc2Platform) DeleteSubnet(ctx context.Context, snId string) error
- func (a *AwsEc2Platform) DeleteVMs(ctx context.Context, vmGroupName, ownerID string) error
- func (a *AwsEc2Platform) DetachPortFromServer(ctx context.Context, serverName string, subnetNames vmlayer.SubnetNames, ...) error
- func (a *AwsEc2Platform) GatherCloudletInfo(ctx context.Context, info *edgeproto.CloudletInfo) error
- func (a *AwsEc2Platform) GetApiEndpointAddr(ctx context.Context) (string, error)
- func (a *AwsEc2Platform) GetCloudletImageSuffix(ctx context.Context) string
- func (a *AwsEc2Platform) GetCloudletInfraResourcesInfo(ctx context.Context) ([]edgeproto.InfraResource, error)
- func (a *AwsEc2Platform) GetCloudletManifest(ctx context.Context, name string, cloudletImagePath string, ...) (string, error)
- func (a *AwsEc2Platform) GetClusterAdditionalResourceMetric(ctx context.Context, cloudlet *edgeproto.Cloudlet, resMetric *edgeproto.Metric, ...) error
- func (a *AwsEc2Platform) GetClusterAdditionalResources(ctx context.Context, cloudlet *edgeproto.Cloudlet, ...) map[string]edgeproto.InfraResource
- func (a *AwsEc2Platform) GetConsoleUrl(ctx context.Context, serverName string) (string, error)
- func (a *AwsEc2Platform) GetElasticIP(ctx context.Context, name, vpcId string) (string, error)
- func (a *AwsEc2Platform) GetExternalGateway(ctx context.Context, extNetName string) (string, error)
- func (o *AwsEc2Platform) GetFeatures() *edgeproto.PlatformFeatures
- func (a *AwsEc2Platform) GetFlavorList(ctx context.Context) ([]*edgeproto.FlavorInfo, error)
- func (a *AwsEc2Platform) GetFreePrecreatedSubnet(ctx context.Context, subnetName, subnetType, vmGroupName string, ...) error
- func (a *AwsEc2Platform) GetGPUSetupStage(ctx context.Context) vmlayer.GPUSetupStage
- func (a *AwsEc2Platform) GetIamAccountForImage(ctx context.Context) (string, error)
- func (a *AwsEc2Platform) GetImageId(ctx context.Context, imageName, accountId string) (string, error)
- func (a *AwsEc2Platform) GetInternalPortPolicy() vmlayer.InternalPortAttachPolicy
- func (a *AwsEc2Platform) GetInternetGateway(ctx context.Context, name string) (*AwsEc2Gateway, error)
- func (a *AwsEc2Platform) GetNatGateway(ctx context.Context, name string) (*AwsEc2NatGateway, error)
- func (a *AwsEc2Platform) GetNetworkInterfaces(ctx context.Context) (*AwsEc2NetworkInterfaceList, error)
- func (a *AwsEc2Platform) GetNetworkList(ctx context.Context) ([]string, error)
- func (a *AwsEc2Platform) GetOutpostFlavorsForCloudletInfo(ctx context.Context, info *edgeproto.CloudletInfo) error
- func (a *AwsEc2Platform) GetPlatformResourceInfo(ctx context.Context) (*vmlayer.PlatformResources, error)
- func (a *AwsEc2Platform) GetResourceID(ctx context.Context, resourceType vmlayer.ResourceType, resourceName string) (string, error)
- func (a *AwsEc2Platform) GetRouteTableId(ctx context.Context, vpcId string, searchType RouteTableSearchType, ...) (string, error)
- func (a *AwsEc2Platform) GetRouterDetail(ctx context.Context, routerName string) (*vmlayer.RouterDetail, error)
- func (a *AwsEc2Platform) GetSecurityGroup(ctx context.Context, name string, vpcId string) (*AwsEc2SecGrp, error)
- func (a *AwsEc2Platform) GetSecurityGroups(ctx context.Context, vpcId string) (map[string]*AwsEc2SecGrp, error)
- func (a *AwsEc2Platform) GetServerDetail(ctx context.Context, vmname string) (*vmlayer.ServerDetail, error)
- func (a *AwsEc2Platform) GetServerGroupResources(ctx context.Context, name string) (*edgeproto.InfraResources, error)
- func (a *AwsEc2Platform) GetSubnet(ctx context.Context, name string) (*AwsEc2Subnet, error)
- func (a *AwsEc2Platform) GetSubnets(ctx context.Context) (map[string]*AwsEc2Subnet, error)
- func (a *AwsEc2Platform) GetVMStats(ctx context.Context, appInst *edgeproto.AppInst) (*vmlayer.VMMetrics, error)
- func (a *AwsEc2Platform) GetVPC(ctx context.Context, name string) (*AwsEc2Vpc, error)
- func (a *AwsEc2Platform) GetVpcName() string
- func (a *AwsEc2Platform) IdSanitize(name string) string
- func (a *AwsEc2Platform) InitApiAccessProperties(ctx context.Context, accessApi platform.AccessApi, vars map[string]string) error
- func (a *AwsEc2Platform) InitData(ctx context.Context, caches *platform.Caches)
- func (a *AwsEc2Platform) InitOperationContext(ctx context.Context, operationStage vmlayer.OperationInitStage) (context.Context, vmlayer.OperationInitResult, error)
- func (a *AwsEc2Platform) InitProvider(ctx context.Context, caches *platform.Caches, stage vmlayer.ProviderInitStage, ...) error
- func (a *AwsEc2Platform) InternalCloudletUpdatedCallback(ctx context.Context, old *edgeproto.CloudletInternal, ...)
- func (a *AwsEc2Platform) NameSanitize(name string) string
- func (a *AwsEc2Platform) PrepareRootLB(ctx context.Context, client ssh.Client, rootLBName string, secGrpName string, ...) error
- func (a *AwsEc2Platform) ReleasePrecreatedSubnet(ctx context.Context, subnetId, vmGroupName, subnetType string) error
- func (a *AwsEc2Platform) RemoveWhitelistSecurityRules(ctx context.Context, client ssh.Client, wlParams *infracommon.WhiteListParams) error
- func (a *AwsEc2Platform) RevokeSecurityGroupRule(ctx context.Context, groupId, protocol, portRange, allowedCIDR string) error
- func (a *AwsEc2Platform) SetPowerState(ctx context.Context, serverName, serverAction string) error
- func (a *AwsEc2Platform) SetVMProperties(vmProperties *vmlayer.VMProperties)
- func (a *AwsEc2Platform) UpdateVMs(ctx context.Context, vmgp *vmlayer.VMGroupOrchestrationParams, ...) error
- func (o *AwsEc2Platform) ValidateAdditionalNetworks(ctx context.Context, additionalNets map[string]vmlayer.NetworkType) error
- func (a *AwsEc2Platform) VerifyVMs(ctx context.Context, vms []edgeproto.VM) error
- func (a *AwsEc2Platform) VmAppChangedCallback(ctx context.Context, appInst *edgeproto.AppInst, ...)
- func (a *AwsEc2Platform) WaitForVMsToBeInState(ctx context.Context, vmGroupName, state string, maxTime time.Duration) error
- func (a *AwsEc2Platform) WhitelistSecurityRules(ctx context.Context, client ssh.Client, wlParams *infracommon.WhiteListParams) error
- type AwsEc2Reservation
- type AwsEc2RouteTable
- type AwsEc2RouteTableAssociation
- type AwsEc2RouteTableCreateResult
- type AwsEc2RouteTableList
- type AwsEc2SecGrp
- type AwsEc2SecGrpList
- type AwsEc2State
- type AwsEc2Subnet
- type AwsEc2SubnetCreateResult
- type AwsEc2SubnetList
- type AwsEc2Tag
- type AwsEc2Vpc
- type AwsEc2VpcCreateResult
- type AwsEc2VpcList
- type AwsIamUser
- type AwsIamUserResult
- type RouteTableSearchType
- type SecurityGroupAction
- type VmGroupResources
Constants ¶
const ElasticIpDoesNotExistError string = "elastic ip does not exist"
const FreeExternalSubnetType string = "free-external"
const FreeInternalSubnetType string = "free-internal"
const GatewayDoesNotExistError string = "gateway does not exist"
const ImageDoesNotExistError string = "image does not exist"
const ImageNotAvailableError string = "image is not available"
const MainRouteTable string = "mainRouteTable"
const MatchAnyGroupName string = "anygroup"
const MatchAnyVmName string = "anyvm"
const NameTag string = "Name"
const ResourceAlreadyAssociatedError string = "Resource.AlreadyAssociated"
const RouteTableDoesNotExistError string = "route table does not exist"
const RuleAlreadyExistsError string = "InvalidPermission.Duplicate"
const RuleDoesNotExistError string = "InvalidPermission.NotFound"
const SecGrpAlreadyExistsError string = "InvalidGroup.Duplicate"
const SecGrpDoesNotExistError string = "InvalidGroup.NotFound"
const SubnetAlreadyExistsError string = "subnet aleady exists"
const SubnetDoesNotExistError string = "subnet does not exist"
const VMGroupNameTag string = "VMGroupName"
const VpcDoesNotExistError string = "vpc does not exist"
Variables ¶
This section is empty.
Functions ¶
func NewPlatform ¶
Types ¶
type AwsEc2Address ¶
type AwsEc2AddressList ¶
type AwsEc2AddressList struct {
Addresses []AwsEc2Address
}
type AwsEc2Gateway ¶
type AwsEc2Gateway struct { InternetGatewayId string Tags []AwsEc2Tag Attachments []AwsEc2GatewayAttachent }
type AwsEc2GatewayAttachent ¶
type AwsEc2GatewayCreateResult ¶
type AwsEc2GatewayCreateResult struct {
InternetGateway AwsEc2Gateway
}
type AwsEc2GatewayList ¶
type AwsEc2GatewayList struct {
InternetGateways []AwsEc2Gateway
}
type AwsEc2Image ¶
type AwsEc2ImageList ¶
type AwsEc2ImageList struct {
Images []AwsEc2Image
}
type AwsEc2Instance ¶
type AwsEc2Instance struct { ImageId string InstanceId string NetworkInterfaces []AwsEc2NetworkInterface Tags []AwsEc2Tag State AwsEc2State }
type AwsEc2Instances ¶
type AwsEc2Instances struct {
Reservations []AwsEc2Reservation
}
type AwsEc2IpAddress ¶
type AwsEc2IpAddress struct { PrivateIpAddress string Association AwsEc2IpAddrPublicIpAssociation }
type AwsEc2NatGateway ¶
type AwsEc2NatGatewayCreateResult ¶
type AwsEc2NatGatewayCreateResult struct {
NatGateway AwsEc2NatGateway
}
type AwsEc2NatGatewayList ¶
type AwsEc2NatGatewayList struct {
NatGateways []AwsEc2NatGateway
}
type AwsEc2NetworkInterface ¶
type AwsEc2NetworkInterface struct { VpcId string SubnetId string MacAddress string NetworkInterfaceId string PrivateIpAddresses []AwsEc2IpAddress Association AwsEc2IpAddrPublicIpAssociation }
type AwsEc2NetworkInterfaceCreateResult ¶
type AwsEc2NetworkInterfaceCreateResult struct {
NetworkInterface AwsEc2NetworkInterface
}
type AwsEc2NetworkInterfaceCreateSpec ¶
type AwsEc2NetworkInterfaceCreateSpec struct { AssociatePublicIpAddress bool `json:"AssociatePublicIpAddress,omitempty"` SubnetId string `json:"SubnetId,omitempty"` PrivateIpAddress string `json:"PrivateIpAddress,omitempty"` Groups []string `json:"Groups,omitempty"` DeviceIndex int `json:"DeviceIndex"` }
type AwsEc2NetworkInterfaceList ¶
type AwsEc2NetworkInterfaceList struct {
NetworkInterfaces []AwsEc2NetworkInterface
}
type AwsEc2Platform ¶
type AwsEc2Platform struct { VMProperties *vmlayer.VMProperties BaseImageId string AmiIamAccountId string VpcCidr string // contains filtered or unexported fields }
func (*AwsEc2Platform) ActiveChanged ¶
func (a *AwsEc2Platform) ActiveChanged(ctx context.Context, platformActive bool) error
func (*AwsEc2Platform) AddImageIfNotPresent ¶
func (a *AwsEc2Platform) AddImageIfNotPresent(ctx context.Context, imageInfo *infracommon.ImageInfo, updateCallback edgeproto.CacheUpdateCallback) error
func (*AwsEc2Platform) AllocateElasticIP ¶
func (a *AwsEc2Platform) AllocateElasticIP(ctx context.Context) (string, error)
func (*AwsEc2Platform) AllowIntraVpcTraffic ¶
func (a *AwsEc2Platform) AllowIntraVpcTraffic(ctx context.Context, groupId string) error
AllowIntraVpcTraffic creates a rule to allow traffic within the VPC
func (*AwsEc2Platform) AssignFreePrecreatedSubnet ¶
func (a *AwsEc2Platform) AssignFreePrecreatedSubnet(ctx context.Context, subnetId, vmGroupName, newName string) error
AssignFreePrecreatedSubnet sets a new name and group tag to denote that the subnet is being used
func (*AwsEc2Platform) AttachPortToServer ¶
func (a *AwsEc2Platform) AttachPortToServer(ctx context.Context, serverName string, subnetNames vmlayer.SubnetNames, portName string, ips infracommon.IPs, action vmlayer.ActionType) error
func (*AwsEc2Platform) CheckServerReady ¶
func (*AwsEc2Platform) ConfigureCloudletSecurityRules ¶
func (a *AwsEc2Platform) ConfigureCloudletSecurityRules(ctx context.Context, egressRestricted bool, TrustPolicy *edgeproto.TrustPolicy, rootLbClients map[string]platform.RootLBClient, action vmlayer.ActionType, updateCallback edgeproto.CacheUpdateCallback) error
func (*AwsEc2Platform) ConfigureTrustPolicyExceptionSecurityRules ¶
func (a *AwsEc2Platform) ConfigureTrustPolicyExceptionSecurityRules(ctx context.Context, TrustPolicyException *edgeproto.TrustPolicyException, rootLbClients map[string]platform.RootLBClient, action vmlayer.ActionType, updateCallback edgeproto.CacheUpdateCallback) error
func (*AwsEc2Platform) CreateImageFromUrl ¶
func (a *AwsEc2Platform) CreateImageFromUrl(ctx context.Context, imageName, imageUrl, md5Sum string) error
CreateImageFromUrl downloads image from URL and then imports to the datastore
func (*AwsEc2Platform) CreateInternalRouteTable ¶
func (a *AwsEc2Platform) CreateInternalRouteTable(ctx context.Context, vpcId, natGwId, name string) (string, error)
CreateInternalRouteTable returns routeTableId, error
func (*AwsEc2Platform) CreateInternetGateway ¶
func (a *AwsEc2Platform) CreateInternetGateway(ctx context.Context, vpcName string) (*AwsEc2Gateway, error)
func (*AwsEc2Platform) CreateInternetGatewayDefaultRoute ¶
func (a *AwsEc2Platform) CreateInternetGatewayDefaultRoute(ctx context.Context, vpcName, vpcId string) error
func (*AwsEc2Platform) CreateNatGateway ¶
func (a *AwsEc2Platform) CreateNatGateway(ctx context.Context, subnetId, elasticIpId, vpcName string) (string, error)
CreateNatGateway returns natGatewayId, error
func (*AwsEc2Platform) CreateSecurityGroup ¶
func (a *AwsEc2Platform) CreateSecurityGroup(ctx context.Context, secGrpname, vpcId, vmGroupName string) (*AwsEc2SecGrp, error)
func (*AwsEc2Platform) CreateSecurityGroupRule ¶
func (a *AwsEc2Platform) CreateSecurityGroupRule(ctx context.Context, groupId, protocol, portRange, allowedCIDR string) error
func (*AwsEc2Platform) CreateSubnet ¶
func (a *AwsEc2Platform) CreateSubnet(ctx context.Context, vmGroupName, name string, cidr string, routeTableId string) (string, error)
CreateSubnet returns subnetId, error
func (*AwsEc2Platform) CreateVM ¶
func (a *AwsEc2Platform) CreateVM(ctx context.Context, groupName string, vm *vmlayer.VMOrchestrationParams, groupPorts []vmlayer.PortOrchestrationParams, resources *VmGroupResources) error
func (*AwsEc2Platform) CreateVMs ¶
func (a *AwsEc2Platform) CreateVMs(ctx context.Context, vmgp *vmlayer.VMGroupOrchestrationParams, updateCallback edgeproto.CacheUpdateCallback) error
CreateVMs creates the VMs and associated resources provided in the group orch params. For AWS, VM creation is done in serial because it returns almost instantly. After creation VMs are polled to see that they are all running.
func (*AwsEc2Platform) DeleteAllResourcesForGroup ¶
func (a *AwsEc2Platform) DeleteAllResourcesForGroup(ctx context.Context, vmGroupName, ownerID string) error
func (*AwsEc2Platform) DeleteImage ¶
func (a *AwsEc2Platform) DeleteImage(ctx context.Context, folder, imageName string) error
func (*AwsEc2Platform) DeleteInstances ¶
func (a *AwsEc2Platform) DeleteInstances(ctx context.Context, instancesIds []string) error
func (*AwsEc2Platform) DeleteSecurityGroup ¶
func (a *AwsEc2Platform) DeleteSecurityGroup(ctx context.Context, groupId, vpcId string) error
func (*AwsEc2Platform) DeleteSubnet ¶
func (a *AwsEc2Platform) DeleteSubnet(ctx context.Context, snId string) error
func (*AwsEc2Platform) DeleteVMs ¶
func (a *AwsEc2Platform) DeleteVMs(ctx context.Context, vmGroupName, ownerID string) error
func (*AwsEc2Platform) DetachPortFromServer ¶
func (a *AwsEc2Platform) DetachPortFromServer(ctx context.Context, serverName string, subnetNames vmlayer.SubnetNames, portName string) error
func (*AwsEc2Platform) GatherCloudletInfo ¶
func (a *AwsEc2Platform) GatherCloudletInfo(ctx context.Context, info *edgeproto.CloudletInfo) error
func (*AwsEc2Platform) GetApiEndpointAddr ¶
func (a *AwsEc2Platform) GetApiEndpointAddr(ctx context.Context) (string, error)
func (*AwsEc2Platform) GetCloudletImageSuffix ¶
func (a *AwsEc2Platform) GetCloudletImageSuffix(ctx context.Context) string
func (*AwsEc2Platform) GetCloudletInfraResourcesInfo ¶
func (a *AwsEc2Platform) GetCloudletInfraResourcesInfo(ctx context.Context) ([]edgeproto.InfraResource, error)
func (*AwsEc2Platform) GetCloudletManifest ¶
func (a *AwsEc2Platform) GetCloudletManifest(ctx context.Context, name string, cloudletImagePath string, vmgp *vmlayer.VMGroupOrchestrationParams) (string, error)
GetCloudletManifest follows the standard practice for vSphere to use OVF for this purpose. We store the OVF in artifactory along with with the vmdk formatted disk. No customization is needed per cloudlet as the OVF import tool will prompt for datastore and portgroup.
func (*AwsEc2Platform) GetClusterAdditionalResourceMetric ¶
func (a *AwsEc2Platform) GetClusterAdditionalResourceMetric(ctx context.Context, cloudlet *edgeproto.Cloudlet, resMetric *edgeproto.Metric, resources []edgeproto.VMResource) error
func (*AwsEc2Platform) GetClusterAdditionalResources ¶
func (a *AwsEc2Platform) GetClusterAdditionalResources(ctx context.Context, cloudlet *edgeproto.Cloudlet, vmResources []edgeproto.VMResource, infraResMap map[string]edgeproto.InfraResource) map[string]edgeproto.InfraResource
func (*AwsEc2Platform) GetConsoleUrl ¶
func (*AwsEc2Platform) GetElasticIP ¶
func (*AwsEc2Platform) GetExternalGateway ¶
func (*AwsEc2Platform) GetFeatures ¶
func (o *AwsEc2Platform) GetFeatures() *edgeproto.PlatformFeatures
func (*AwsEc2Platform) GetFlavorList ¶
func (a *AwsEc2Platform) GetFlavorList(ctx context.Context) ([]*edgeproto.FlavorInfo, error)
func (*AwsEc2Platform) GetFreePrecreatedSubnet ¶
func (a *AwsEc2Platform) GetFreePrecreatedSubnet(ctx context.Context, subnetName, subnetType, vmGroupName string, subnets map[string]*AwsEc2Subnet) error
GetFreePrecreatedSubnet finds a free pre-created subnet of the given type and then assigns it
func (*AwsEc2Platform) GetGPUSetupStage ¶
func (a *AwsEc2Platform) GetGPUSetupStage(ctx context.Context) vmlayer.GPUSetupStage
func (*AwsEc2Platform) GetIamAccountForImage ¶
func (a *AwsEc2Platform) GetIamAccountForImage(ctx context.Context) (string, error)
GetIamAccountForImage gets the account Id, which is either the logged in account or the account specified as the GetAmiIamOwner
func (*AwsEc2Platform) GetImageId ¶
func (*AwsEc2Platform) GetInternalPortPolicy ¶
func (a *AwsEc2Platform) GetInternalPortPolicy() vmlayer.InternalPortAttachPolicy
func (*AwsEc2Platform) GetInternetGateway ¶
func (a *AwsEc2Platform) GetInternetGateway(ctx context.Context, name string) (*AwsEc2Gateway, error)
func (*AwsEc2Platform) GetNatGateway ¶
func (a *AwsEc2Platform) GetNatGateway(ctx context.Context, name string) (*AwsEc2NatGateway, error)
func (*AwsEc2Platform) GetNetworkInterfaces ¶
func (a *AwsEc2Platform) GetNetworkInterfaces(ctx context.Context) (*AwsEc2NetworkInterfaceList, error)
func (*AwsEc2Platform) GetNetworkList ¶
func (a *AwsEc2Platform) GetNetworkList(ctx context.Context) ([]string, error)
func (*AwsEc2Platform) GetOutpostFlavorsForCloudletInfo ¶
func (a *AwsEc2Platform) GetOutpostFlavorsForCloudletInfo(ctx context.Context, info *edgeproto.CloudletInfo) error
func (*AwsEc2Platform) GetPlatformResourceInfo ¶
func (a *AwsEc2Platform) GetPlatformResourceInfo(ctx context.Context) (*vmlayer.PlatformResources, error)
func (*AwsEc2Platform) GetResourceID ¶
func (a *AwsEc2Platform) GetResourceID(ctx context.Context, resourceType vmlayer.ResourceType, resourceName string) (string, error)
func (*AwsEc2Platform) GetRouteTableId ¶
func (a *AwsEc2Platform) GetRouteTableId(ctx context.Context, vpcId string, searchType RouteTableSearchType, name string) (string, error)
func (*AwsEc2Platform) GetRouterDetail ¶
func (a *AwsEc2Platform) GetRouterDetail(ctx context.Context, routerName string) (*vmlayer.RouterDetail, error)
func (*AwsEc2Platform) GetSecurityGroup ¶
func (a *AwsEc2Platform) GetSecurityGroup(ctx context.Context, name string, vpcId string) (*AwsEc2SecGrp, error)
GetSecurityGroup returns a single group with the name
func (*AwsEc2Platform) GetSecurityGroups ¶
func (a *AwsEc2Platform) GetSecurityGroups(ctx context.Context, vpcId string) (map[string]*AwsEc2SecGrp, error)
GetSecurityGroups returns a map of name to group for all groups in the VPC
func (*AwsEc2Platform) GetServerDetail ¶
func (a *AwsEc2Platform) GetServerDetail(ctx context.Context, vmname string) (*vmlayer.ServerDetail, error)
func (*AwsEc2Platform) GetServerGroupResources ¶
func (a *AwsEc2Platform) GetServerGroupResources(ctx context.Context, name string) (*edgeproto.InfraResources, error)
func (*AwsEc2Platform) GetSubnet ¶
func (a *AwsEc2Platform) GetSubnet(ctx context.Context, name string) (*AwsEc2Subnet, error)
func (*AwsEc2Platform) GetSubnets ¶
func (a *AwsEc2Platform) GetSubnets(ctx context.Context) (map[string]*AwsEc2Subnet, error)
func (*AwsEc2Platform) GetVMStats ¶
func (*AwsEc2Platform) GetVpcName ¶
func (a *AwsEc2Platform) GetVpcName() string
func (*AwsEc2Platform) IdSanitize ¶
func (a *AwsEc2Platform) IdSanitize(name string) string
AwsEc2Platform IdSanitize is the same as NameSanitize
func (*AwsEc2Platform) InitApiAccessProperties ¶
func (*AwsEc2Platform) InitData ¶
func (a *AwsEc2Platform) InitData(ctx context.Context, caches *platform.Caches)
func (*AwsEc2Platform) InitOperationContext ¶
func (a *AwsEc2Platform) InitOperationContext(ctx context.Context, operationStage vmlayer.OperationInitStage) (context.Context, vmlayer.OperationInitResult, error)
func (*AwsEc2Platform) InitProvider ¶
func (a *AwsEc2Platform) InitProvider(ctx context.Context, caches *platform.Caches, stage vmlayer.ProviderInitStage, updateCallback edgeproto.CacheUpdateCallback) error
func (*AwsEc2Platform) InternalCloudletUpdatedCallback ¶
func (a *AwsEc2Platform) InternalCloudletUpdatedCallback(ctx context.Context, old *edgeproto.CloudletInternal, new *edgeproto.CloudletInternal)
func (*AwsEc2Platform) NameSanitize ¶
func (a *AwsEc2Platform) NameSanitize(name string) string
func (*AwsEc2Platform) PrepareRootLB ¶
func (a *AwsEc2Platform) PrepareRootLB(ctx context.Context, client ssh.Client, rootLBName string, secGrpName string, TrustPolicy *edgeproto.TrustPolicy, updateCallback edgeproto.CacheUpdateCallback) error
func (*AwsEc2Platform) ReleasePrecreatedSubnet ¶
func (a *AwsEc2Platform) ReleasePrecreatedSubnet(ctx context.Context, subnetId, vmGroupName, subnetType string) error
ReleasePrecreatedSubnet removes the group tag and sets the name tag back to free-<type>
func (*AwsEc2Platform) RemoveWhitelistSecurityRules ¶
func (a *AwsEc2Platform) RemoveWhitelistSecurityRules(ctx context.Context, client ssh.Client, wlParams *infracommon.WhiteListParams) error
func (*AwsEc2Platform) RevokeSecurityGroupRule ¶
func (a *AwsEc2Platform) RevokeSecurityGroupRule(ctx context.Context, groupId, protocol, portRange, allowedCIDR string) error
func (*AwsEc2Platform) SetPowerState ¶
func (a *AwsEc2Platform) SetPowerState(ctx context.Context, serverName, serverAction string) error
func (*AwsEc2Platform) SetVMProperties ¶
func (a *AwsEc2Platform) SetVMProperties(vmProperties *vmlayer.VMProperties)
func (*AwsEc2Platform) UpdateVMs ¶
func (a *AwsEc2Platform) UpdateVMs(ctx context.Context, vmgp *vmlayer.VMGroupOrchestrationParams, updateCallback edgeproto.CacheUpdateCallback) error
UpdateVMs calculates which VMs need to be added or removed from the given group and then does so.
func (*AwsEc2Platform) ValidateAdditionalNetworks ¶
func (o *AwsEc2Platform) ValidateAdditionalNetworks(ctx context.Context, additionalNets map[string]vmlayer.NetworkType) error
func (*AwsEc2Platform) VmAppChangedCallback ¶
func (a *AwsEc2Platform) VmAppChangedCallback(ctx context.Context, appInst *edgeproto.AppInst, newState edgeproto.TrackedState)
func (*AwsEc2Platform) WaitForVMsToBeInState ¶
func (*AwsEc2Platform) WhitelistSecurityRules ¶
func (a *AwsEc2Platform) WhitelistSecurityRules(ctx context.Context, client ssh.Client, wlParams *infracommon.WhiteListParams) error
type AwsEc2Reservation ¶
type AwsEc2Reservation struct {
Instances []AwsEc2Instance
}
type AwsEc2RouteTable ¶
type AwsEc2RouteTable struct { RouteTableId string VpcId string Associations []AwsEc2RouteTableAssociation Tags []AwsEc2Tag }
type AwsEc2RouteTableCreateResult ¶
type AwsEc2RouteTableCreateResult struct {
RouteTable AwsEc2RouteTable
}
type AwsEc2RouteTableList ¶
type AwsEc2RouteTableList struct {
RouteTables []AwsEc2RouteTable
}
type AwsEc2SecGrp ¶
type AwsEc2SecGrpList ¶
type AwsEc2SecGrpList struct {
SecurityGroups []AwsEc2SecGrp
}
type AwsEc2State ¶
type AwsEc2Subnet ¶
type AwsEc2SubnetCreateResult ¶
type AwsEc2SubnetCreateResult struct {
Subnet AwsEc2Subnet
}
type AwsEc2SubnetList ¶
type AwsEc2SubnetList struct {
Subnets []AwsEc2Subnet
}
type AwsEc2VpcCreateResult ¶
type AwsEc2VpcCreateResult struct {
Vpc AwsEc2Vpc
}
type AwsEc2VpcList ¶
type AwsEc2VpcList struct {
Vpcs []AwsEc2Vpc
}
type AwsIamUser ¶
type AwsIamUserResult ¶
type AwsIamUserResult struct {
User AwsIamUser
}
type RouteTableSearchType ¶
type RouteTableSearchType string
const SearchForMainRouteTable RouteTableSearchType = "main"
const SearchForRouteTableByName RouteTableSearchType = "name"
type SecurityGroupAction ¶
type SecurityGroupAction string
const SecurityGroupRuleCreate SecurityGroupAction = "create"
const SecurityGroupRuleRevoke SecurityGroupAction = "revoke"
type VmGroupResources ¶
type VmGroupResources struct { VpcId string SecGrpMap map[string]*AwsEc2SecGrp SubnetMap map[string]*AwsEc2Subnet // contains filtered or unexported fields }