alicloud

package
v1.7.1 Latest Latest
Warning

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

Go to latest
Published: Feb 2, 2018 License: MPL-2.0 Imports: 33 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ClassicNet = InstanceNetWork("classic")
	VpcNet     = InstanceNetWork("vpc")
)
View Source
const (
	Http  = Protocol("http")
	Https = Protocol("https")
	Tcp   = Protocol("tcp")
	Udp   = Protocol("udp")
)

Constants of protocol definition

View Source
const (
	ZoneKey                       = ResourceKeyType("zones")
	InstanceTypeKey               = ResourceKeyType("instanceTypes")
	OutdatedInstanceTypeKey       = ResourceKeyType("outdatedInstanceTypes")
	UpgradedInstanceTypeKey       = ResourceKeyType("upgradedInstanceTypes")
	InstanceTypeFamilyKey         = ResourceKeyType("instanceTypeFamilies")
	OutdatedInstanceTypeFamilyKey = ResourceKeyType("outdatedInstanceTypeFamilies")
	UpgradedInstanceTypeFamilyKey = ResourceKeyType("upgradedInstanceTypeFamilies")
	DiskCategoryKey               = ResourceKeyType("diskCatetories")
	OutdatedDiskCategoryKey       = ResourceKeyType("outdatedDiskCatetories")
	IoOptimizedKey                = ResourceKeyType("optimized")
)
View Source
const (
	// common
	Notfound = "Not found"
	// ecs
	InstanceNotFound        = "Instance.Notfound"
	MessageInstanceNotFound = "instance is not found"
	EcsThrottling           = "Throttling"
	EcsInternalError        = "InternalError"
	// disk
	DiskIncorrectStatus       = "IncorrectDiskStatus"
	DiskCreatingSnapshot      = "DiskCreatingSnapshot"
	InstanceLockedForSecurity = "InstanceLockedForSecurity"
	SystemDiskNotFound        = "SystemDiskNotFound"
	DiskOperationConflict     = "OperationConflict"
	DiskInternalError         = "InternalError"
	DiskInvalidOperation      = "InvalidOperation.Conflict"
	// eip
	EipIncorrectStatus         = "IncorrectEipStatus"
	InstanceIncorrectStatus    = "IncorrectInstanceStatus"
	HaVipIncorrectStatus       = "IncorrectHaVipStatus"
	COMMODITYINVALID_COMPONENT = "COMMODITY.INVALID_COMPONENT"
	// slb
	LoadBalancerNotFound        = "InvalidLoadBalancerId.NotFound"
	UnsupportedProtocalPort     = "UnsupportedOperationonfixedprotocalport"
	ListenerNotFound            = "The specified resource does not exist"
	ListenerAlreadyExists       = "ListenerAlreadyExists"
	ServiceIsConfiguring        = "ServiceIsConfiguring"
	ServiceIsStopping           = "ServiceIsStopping"
	BackendServerconfiguring    = "BackendServer.configuring"
	SystemBusy                  = "SystemBusy"
	SlbOrderFailed              = "OrderFailed"
	VServerGroupNotFoundMessage = "The specified VServerGroupId does not exist"
	RspoolVipExist              = "RspoolVipExist"
	InvalidParameter            = "InvalidParameter"
	InvalidRuleIdNotFound       = "InvalidRuleId.NotFound"
	RuleDomainExist             = "DomainExist"
	// security_group
	InvalidInstanceIdAlreadyExists = "InvalidInstanceId.AlreadyExists"
	InvalidSecurityGroupIdNotFound = "InvalidSecurityGroupId.NotFound"
	SgDependencyViolation          = "DependencyViolation"

	//Nat gateway
	NatGatewayInvalidRegionId            = "Invalid.RegionId"
	DependencyViolationBandwidthPackages = "DependencyViolation.BandwidthPackages"
	NotFindSnatEntryBySnatId             = "NotFindSnatEntryBySnatId"
	NotFindForwardEntryByForwardId       = "NotFindForwardEntryByForwardId"
	VswitchStatusError                   = "VswitchStatusError"
	// vpc
	VpcQuotaExceeded = "QuotaExceeded.Vpc"
	// vswitch
	VswitcInvalidRegionId = "InvalidRegionId.NotFound"
	//vroute entry
	IncorrectRouteEntryStatus     = "IncorrectRouteEntryStatus"
	TaskConflict                  = "TaskConflict"
	RouterEntryForbbiden          = "Forbbiden"
	RouterEntryConflictDuplicated = "RouterEntryConflict.Duplicated"

	// ess
	InvalidScalingGroupIdNotFound               = "InvalidScalingGroupId.NotFound"
	IncorrectScalingConfigurationLifecycleState = "IncorrectScalingConfigurationLifecycleState"
	IncorrectScalingGroupStatus                 = "IncorrectScalingGroupStatus"
	IncorrectCapacityMaxSize                    = "IncorrectCapacity.MaxSize"
	IncorrectCapacityMinSize                    = "IncorrectCapacity.MinSize"
	ScalingActivityInProgress                   = "ScalingActivityInProgress"
	EssThrottling                               = "Throttling"
	// rds
	InvalidDBInstanceIdNotFound            = "InvalidDBInstanceId.NotFound"
	InvalidDBNameNotFound                  = "InvalidDBName.NotFound"
	InvalidDBInstanceNameNotFound          = "InvalidDBInstanceName.NotFound"
	InvalidCurrentConnectionStringNotFound = "InvalidCurrentConnectionString.NotFound"
	NetTypeExists                          = "NetTypeExists"
	InvalidAccountNameDuplicate            = "InvalidAccountName.Duplicate"
	InvalidAccountNameNotFound             = "InvalidAccountName.NotFound"
	OperationDeniedDBInstanceStatus        = "OperationDenied.DBInstanceStatus"
	InvalidConnectionStringDuplicate       = "InvalidConnectionString.Duplicate"
	AtLeastOneNetTypeExists                = "AtLeastOneNetTypeExists"
	ConnectionOperationDenied              = "OperationDenied"
	ConnectionConflictMessage              = "The requested resource is sold out in the specified zone; try other types of resources or other regions and zones"
	DBInternalError                        = "InternalError"
	// oss
	OssBucketNotFound = "NoSuchBucket"
	OssBodyNotFound   = "404 Not Found"

	// RAM Instance Not Found
	RamInstanceNotFound   = "Forbidden.InstanceNotFound"
	AliyunGoClientFailure = "AliyunGoClientFailure"

	// dns
	RecordForbiddenDNSChange    = "RecordForbidden.DNSChange"
	FobiddenNotEmptyGroup       = "Fobidden.NotEmptyGroup"
	DomainRecordNotBelongToUser = "DomainRecordNotBelongToUser"

	// ram user
	DeleteConflictUserGroup        = "DeleteConflict.User.Group"
	DeleteConflictUserAccessKey    = "DeleteConflict.User.AccessKey"
	DeleteConflictUserLoginProfile = "DeleteConflict.User.LoginProfile"
	DeleteConflictUserMFADevice    = "DeleteConflict.User.MFADevice"
	DeleteConflictUserPolicy       = "DeleteConflict.User.Policy"

	// ram mfa
	DeleteConflictVirtualMFADeviceUser = "DeleteConflict.VirtualMFADevice.User"

	// ram group
	DeleteConflictGroupUser   = "DeleteConflict.Group.User"
	DeleteConflictGroupPolicy = "DeleteConflict.Group.Policy"

	// ram role
	DeleteConflictRolePolicy = "DeleteConflict.Role.Policy"

	// ram policy
	DeleteConflictPolicyUser    = "DeleteConflict.Policy.User"
	DeleteConflictPolicyGroup   = "DeleteConflict.Policy.Group"
	DeleteConflictPolicyVersion = "DeleteConflict.Policy.Version"

	//unknown Error
	UnknownError = "UnknownError"

	// Keypair error
	KeyPairNotFound           = "InvalidKeyPair.NotFound"
	KeyPairServiceUnavailable = "ServiceUnavailable"

	// Container
	ErrorClusterNotFound = "ErrorClusterNotFound"

	// cdn
	ServiceBusy = "ServiceBusy"

	// KMS
	ForbiddenKeyNotFound = "Forbidden.KeyNotFound"
	// RAM
	InvalidRamRoleNotFound       = "InvalidRamRole.NotFound"
	RoleAttachmentUnExpectedJson = "unexpected end of JSON input"
	InvalidInstanceIdNotFound    = "InvalidInstanceId.NotFound"

	RouterInterfaceIncorrectStatus                        = "IncorrectStatus"
	DependencyViolationRouterInterfaceReferedByRouteEntry = "DependencyViolation.RouterInterfaceReferedByRouteEntry"
)
View Source
const (
	GroupRuleInternet = GroupRuleNicType("internet")
	GroupRuleIntranet = GroupRuleNicType("intranet")
)
View Source
const (
	GroupRulePolicyAccept = GroupRulePolicy("accept")
	GroupRulePolicyDrop   = GroupRulePolicy("drop")
)
View Source
const (
	EcsApiVersion20160314 = "2016-03-14"
	EcsApiVersion20140526 = "2014-05-26"
)
View Source
const (
	Enabled         = KeyState("Enabled")
	Disabled        = KeyState("Disabled")
	PendingDeletion = KeyState("PendingDeletion")
)
View Source
const (
	ExpirationStatusEnabled  = LifecycleRuleStatus("Enabled")
	ExpirationStatusDisabled = LifecycleRuleStatus("Disabled")
)
View Source
const AllPortRange = "-1/-1"
View Source
const BusinessInfoKey = "Terraform"
View Source
const COLON_SEPARATED = ":"
View Source
const COMMA_SEPARATED = ","
View Source
const CharityPageUrl = "http://promotion.alicdn.com/help/oss/error.html"
View Source
const DBConnectionSuffix = ".mysql.rds.aliyuncs.com"
View Source
const DB_DEFAULT_CONNECT_PORT = "3306"

default connect port of db

View Source
const DEFAULT_DB_SECURITY_IP = "127.0.0.1"

default security ip for db

View Source
const DEFAULT_INSTANCE_COUNT = 1

we the count of create instance is only one

View Source
const DEFAULT_REGION = "cn-beijing"

default region for all resource

View Source
const DOT_SEPARATED = "."
View Source
const GenerationFour = "ecs-4"
View Source
const GenerationOne = "ecs-1"
View Source
const GenerationThree = "ecs-3"
View Source
const GenerationTwo = "ecs-2"
View Source
const LOCAL_HOST_IP = "127.0.0.1"
View Source
const MULTI_IZ_SYMBOL = "MAZ"

symbol of multiIZ

View Source
const Negative = ecs.Spec("Negative")
View Source
const ServerSideEncryptionAes256 = "AES256"

Variables

View Source
var DefaultBusinessInfo = ecs.BusinessInfo{
	Pack: "terraform",
}
View Source
var HalfIoOptimizedFamily = map[string]string{"ecs.s2": "", "ecs.s3": "", "ecs.m1": "", "ecs.m2": "", "ecs.c1": "", "ecs.c2": ""}
View Source
var NoneIoOptimizedFamily = map[string]string{"ecs.t1": "", "ecs.t2": "", "ecs.s1": ""}
View Source
var NoneIoOptimizedInstanceType = map[string]string{"ecs.s2.small": ""}
View Source
var ValidProtocols = []Protocol{Http, Https, Tcp, Udp}

ValidProtocols network protocol list

Functions

func AddTags

func AddTags(client *ecs.Client, args *AddTagsArgs) error

func AssemblePolicyDocument added in v1.2.0

func AssemblePolicyDocument(document []interface{}, version string) (string, error)

func AssembleRolePolicyDocument added in v1.2.0

func AssembleRolePolicyDocument(ramUser, service []interface{}, version string) (string, error)

func GetAllRouterInterfaceSpec added in v0.1.1

func GetAllRouterInterfaceSpec() (specifications []string)

func GetIntersection added in v1.2.0

func GetIntersection(dataMap []map[string]interface{}, allDataMap map[string]interface{}) (allData []interface{})

func GetNotFoundErrorFromString

func GetNotFoundErrorFromString(str string) error

func IsExceptedError added in v0.1.1

func IsExceptedError(err error, expectCode string) bool

func NotFoundError added in v0.1.1

func NotFoundError(err error) bool

func ParsePolicyDocument added in v1.2.0

func ParsePolicyDocument(policyDocument string) (statement []map[string]interface{}, version string, err error)

func Provider

func Provider() terraform.ResourceProvider

Provider returns a schema.Provider for alicloud

func RamEntityNotExist added in v1.2.0

func RamEntityNotExist(err error) bool

func RemoveTags

func RemoveTags(client *ecs.Client, args *RemoveTagsArgs) error

func String

func String(v string) *string

func TransformPeriod2Time

func TransformPeriod2Time(period int, chargeType string) (ut int, tt common.TimeType)

turn period to TimeType

func TransformTime2Period

func TransformTime2Period(ut int, tt common.TimeType) (period int)

turn TimeType to Period

Types

type AddTagsArgs

type AddTagsArgs struct {
	ResourceId   string
	ResourceType ecs.TagResourceType //image, instance, snapshot or disk
	RegionId     common.Region
	Tag          []Tag
}

type AliyunClient

type AliyunClient struct {
	Region common.Region
	// contains filtered or unexported fields
}

AliyunClient of aliyun

func (*AliyunClient) ActiveScalingConfigurationById

func (client *AliyunClient) ActiveScalingConfigurationById(sgId, configId string) error

func (*AliyunClient) AllocateDBPublicConnection

func (client *AliyunClient) AllocateDBPublicConnection(instanceId, prefix, port string) error

func (*AliyunClient) CheckParameterValidity added in v0.1.1

func (client *AliyunClient) CheckParameterValidity(d *schema.ResourceData, meta interface{}) (map[ResourceKeyType]interface{}, error)

func (*AliyunClient) ConfigDBBackup

func (client *AliyunClient) ConfigDBBackup(instanceId, backupTime, backupPeriod string, retentionPeriod int) error

func (*AliyunClient) DeleteScalingGroupById

func (client *AliyunClient) DeleteScalingGroupById(sgId string) error

func (*AliyunClient) DeleteScalingRuleById

func (client *AliyunClient) DeleteScalingRuleById(ruleId string) error

func (*AliyunClient) DeleteScheduleById

func (client *AliyunClient) DeleteScheduleById(scheduleId string) error

func (*AliyunClient) DescribeDBInstanceById

func (client *AliyunClient) DescribeDBInstanceById(id string) (instance *rds.DBInstanceAttribute, err error)
_______________                      _______________                       _______________
|              | ______param______\  |              |  _____request_____\  |              |
|   Business   |                     |    Service   |                      |    SDK/API   |
|              | __________________  |              |  __________________  |              |
|______________| \    (obj, err)     |______________|  \ (status, cont)    |______________|
                    |                                    |
                    |A. {instance, nil}                  |a. {200, content}
                    |B. {nil, error}                     |b. {200, nil}
               					  |c. {4xx, nil}

The API return 200 for resource not found. When getInstance is empty, then throw InstanceNotfound error. That the business layer only need to check error.

func (*AliyunClient) DescribeDBInstanceNetInfoByIpType added in v1.5.0

func (client *AliyunClient) DescribeDBInstanceNetInfoByIpType(instanceId string, ipType rds.IPType) (*rds.DBInstanceNetInfo, error)

func (*AliyunClient) DescribeDBInstanceNetInfos added in v1.5.0

func (client *AliyunClient) DescribeDBInstanceNetInfos(instanceId string) ([]rds.DBInstanceNetInfo, error)

func (*AliyunClient) DescribeDBSecurityIps

func (client *AliyunClient) DescribeDBSecurityIps(instanceId string) (ips []rds.DBInstanceIPList, err error)

func (*AliyunClient) DescribeDatabaseAccount added in v1.5.0

func (client *AliyunClient) DescribeDatabaseAccount(instanceId, accountName string) (ds *rds.DBInstanceAccount, err error)

func (*AliyunClient) DescribeDatabaseByName

func (client *AliyunClient) DescribeDatabaseByName(instanceId, dbName string) (ds *rds.Database, err error)

func (*AliyunClient) DescribeEipAddress

func (client *AliyunClient) DescribeEipAddress(allocationId string) (*ecs.EipAddressSetType, error)

func (*AliyunClient) DescribeForwardEntry

func (client *AliyunClient) DescribeForwardEntry(forwardTableId string, forwardEntryId string) (ecs.ForwardTableEntrySetType, error)

func (*AliyunClient) DescribeImage

func (client *AliyunClient) DescribeImage(imageId string) (*ecs.ImageType, error)

func (*AliyunClient) DescribeLoadBalancerAttribute

func (client *AliyunClient) DescribeLoadBalancerAttribute(slbId string) (*slb.LoadBalancerType, error)

func (*AliyunClient) DescribeLoadBalancerRuleId added in v1.7.0

func (client *AliyunClient) DescribeLoadBalancerRuleId(slbId string, port int, domain, url string) (string, error)

func (*AliyunClient) DescribeMultiIZByRegion

func (client *AliyunClient) DescribeMultiIZByRegion() (izs []string, err error)

return multiIZ list of current region

func (*AliyunClient) DescribeNatGateway

func (client *AliyunClient) DescribeNatGateway(natGatewayId string) (*ecs.NatGatewaySetType, error)

func (*AliyunClient) DescribeScalingConfigurationById

func (client *AliyunClient) DescribeScalingConfigurationById(configId string) (*ess.ScalingConfigurationItemType, error)

func (*AliyunClient) DescribeScalingGroupById

func (client *AliyunClient) DescribeScalingGroupById(sgId string) (*ess.ScalingGroupItemType, error)

func (*AliyunClient) DescribeScalingRuleById

func (client *AliyunClient) DescribeScalingRuleById(sgId, ruleId string) (*ess.ScalingRuleItemType, error)

func (*AliyunClient) DescribeScheduleById

func (client *AliyunClient) DescribeScheduleById(scheduleId string) (*ess.ScheduledTaskItemType, error)

func (*AliyunClient) DescribeSecurity

func (client *AliyunClient) DescribeSecurity(securityGroupId string) (*ecs.DescribeSecurityGroupAttributeResponse, error)

func (*AliyunClient) DescribeSecurityGroupRule

func (client *AliyunClient) DescribeSecurityGroupRule(groupId, direction, ipProtocol, portRange, nicType, cidr_ip, policy string, priority int) (*ecs.PermissionType, error)

func (*AliyunClient) DescribeSnatEntry

func (client *AliyunClient) DescribeSnatEntry(snatTableId string, snatEntryId string) (ecs.SnatEntrySetType, error)

func (*AliyunClient) DescribeVpc

func (client *AliyunClient) DescribeVpc(vpcId string) (*ecs.VpcSetType, error)

func (*AliyunClient) DescribeZone

func (client *AliyunClient) DescribeZone(zoneID string) (*ecs.ZoneType, error)

DescribeZone validate zoneId is valid in region

func (*AliyunClient) DiskAvailable

func (client *AliyunClient) DiskAvailable(zone *ecs.ZoneType, diskCategory ecs.DiskCategory) error

func (*AliyunClient) EssRemoveInstances added in v1.7.0

func (client *AliyunClient) EssRemoveInstances(groupId string, instanceIds []string) error

func (*AliyunClient) FetchSpecifiedInstanceTypeFamily added in v0.1.1

func (client *AliyunClient) FetchSpecifiedInstanceTypeFamily(regionId common.Region, zoneId string, generations []string, all_zones []ecs.ZoneType) (map[string]ecs.InstanceTypeFamily, map[string]ecs.InstanceTypeFamily, error)

func (*AliyunClient) FetchSpecifiedInstanceTypesByFamily added in v0.1.1

func (client *AliyunClient) FetchSpecifiedInstanceTypesByFamily(zoneId, instanceTypeFamily string, all_zones []ecs.ZoneType) (map[string]ecs.InstanceTypeItemType, error)

func (*AliyunClient) GetSecurityIps

func (client *AliyunClient) GetSecurityIps(instanceId string, securityIps interface{}) ([]string, error)

func (*AliyunClient) GetVpcIdByVSwitchId

func (client *AliyunClient) GetVpcIdByVSwitchId(vswitchId string) (vpcId string, err error)

func (*AliyunClient) GrantAccountPrivilege added in v1.5.0

func (client *AliyunClient) GrantAccountPrivilege(instanceId, account, dbName, privilege string) error

func (*AliyunClient) JoinSecurityGroups

func (client *AliyunClient) JoinSecurityGroups(instanceId string, securityGroupIds []string) error

todo: support syc

func (*AliyunClient) JudgeRegionValidation added in v0.1.1

func (client *AliyunClient) JudgeRegionValidation(key string, region common.Region) error

func (*AliyunClient) JudgeRolePolicyPrincipal added in v1.2.0

func (client *AliyunClient) JudgeRolePolicyPrincipal(roleName string) error

Judge whether the role policy contains service "ecs.aliyuncs.com"

func (*AliyunClient) LeaveSecurityGroups

func (client *AliyunClient) LeaveSecurityGroups(instanceId string, securityGroupIds []string) error

func (*AliyunClient) ModifyDBClassStorage

func (client *AliyunClient) ModifyDBClassStorage(instanceId, class, storage string) error

func (*AliyunClient) ModifyDBSecurityIps

func (client *AliyunClient) ModifyDBSecurityIps(instanceId, ips string) error

func (*AliyunClient) QueryInstanceSystemDisk

func (client *AliyunClient) QueryInstanceSystemDisk(id string) (disk *ecs.DiskItemType, err error)

func (*AliyunClient) QueryInstancesById

func (client *AliyunClient) QueryInstancesById(id string) (instance *ecs.InstanceAttributesType, err error)

func (*AliyunClient) QueryInstancesByIds

func (client *AliyunClient) QueryInstancesByIds(ids []string) (instances []ecs.InstanceAttributesType, err error)

func (*AliyunClient) QueryInstancesWithKeyPair added in v0.1.1

func (client *AliyunClient) QueryInstancesWithKeyPair(region common.Region, instanceIds, keypair string) ([]interface{}, []ecs.InstanceAttributesType, error)

func (*AliyunClient) QueryOssBucketById added in v0.1.1

func (client *AliyunClient) QueryOssBucketById(id string) (info *oss.BucketInfo, err error)

func (*AliyunClient) QueryRouteEntry

func (client *AliyunClient) QueryRouteEntry(routeTableId, cidrBlock, nextHopType, nextHopId string) (rn *ecs.RouteEntrySetType, err error)

func (*AliyunClient) QueryRouteTableById

func (client *AliyunClient) QueryRouteTableById(routeTableId string) (rt *ecs.RouteTableSetType, err error)

func (*AliyunClient) QueryRouteTables

func (client *AliyunClient) QueryRouteTables(args *ecs.DescribeRouteTablesArgs) (routeTables []ecs.RouteTableSetType, err error)

func (*AliyunClient) QueryVswitchById

func (client *AliyunClient) QueryVswitchById(vpcId, vswitchId string) (vsw *ecs.VSwitchSetType, err error)

func (*AliyunClient) QueryVswitches

func (client *AliyunClient) QueryVswitches(args *ecs.DescribeVSwitchesArgs) (vswitches []ecs.VSwitchSetType, err error)

describe vswitch by param filters

func (*AliyunClient) ReleaseDBPublicConnection added in v1.5.0

func (client *AliyunClient) ReleaseDBPublicConnection(instanceId, connection string) error

func (*AliyunClient) ResourceAvailable

func (client *AliyunClient) ResourceAvailable(zone *ecs.ZoneType, resourceType ecs.ResourceType) error

ResourceAvailable check resource available for zone

func (*AliyunClient) RevokeAccountPrivilege added in v1.5.0

func (client *AliyunClient) RevokeAccountPrivilege(instanceId, account, dbName string) error

func (*AliyunClient) RevokeSecurityGroup

func (client *AliyunClient) RevokeSecurityGroup(args *ecs.RevokeSecurityGroupArgs) error

func (*AliyunClient) RevokeSecurityGroupEgress

func (client *AliyunClient) RevokeSecurityGroupEgress(args *ecs.RevokeSecurityGroupEgressArgs) error

func (*AliyunClient) SwitchDBInstanceNetType added in v1.5.0

func (client *AliyunClient) SwitchDBInstanceNetType(instanceId, prefix string, port int, vswitchId string) error

type Config

type Config struct {
	AccessKey     string
	SecretKey     string
	Region        common.Region
	SecurityToken string
}

Config of aliyun

func (*Config) Client

func (c *Config) Client() (*AliyunClient, error)

Client for AliyunClient

type Effect added in v1.2.0

type Effect string
const (
	Allow Effect = "Allow"
	Deny  Effect = "Deny"
)

type GroupRuleNicType

type GroupRuleNicType string

type GroupRulePolicy

type GroupRulePolicy string

type InstanceNetWork

type InstanceNetWork string

type KeyState added in v1.7.0

type KeyState string

type LifecycleRuleStatus added in v0.1.1

type LifecycleRuleStatus string

type Listener

type Listener struct {
	slb.HTTPListenerType

	InstancePort     int
	LoadBalancerPort int
	Protocol         string
	//tcp & udp
	PersistenceTimeout int

	//https
	SSLCertificateId string

	//tcp
	HealthCheckType slb.HealthCheckType

	//api interface: http & https is HealthCheckTimeout, tcp & udp is HealthCheckConnectTimeout
	HealthCheckConnectTimeout int
}

type ListenerErr

type ListenerErr struct {
	ErrType string
	Err     error
}

func (*ListenerErr) Error

func (e *ListenerErr) Error() string

type Policy added in v1.2.0

type Policy struct {
	Statement []PolicyStatement
	Version   string
}

type PolicyStatement added in v1.2.0

type PolicyStatement struct {
	Effect   Effect
	Action   interface{}
	Resource interface{}
}

type Principal added in v1.2.0

type Principal struct {
	Service []string
	RAM     []string
}

type Protocol

type Protocol string

Protocol represents network protocol

type RemoveTagsArgs

type RemoveTagsArgs struct {
	ResourceId   string
	ResourceType ecs.TagResourceType //image, instance, snapshot or disk
	RegionId     common.Region
	Tag          []Tag
}

type ResourceKeyType added in v0.1.1

type ResourceKeyType string

type RolePolicy added in v1.2.0

type RolePolicy struct {
	Statement []RolePolicyStatement
	Version   string
}

func ParseRolePolicyDocument added in v1.2.0

func ParseRolePolicyDocument(policyDocument string) (RolePolicy, error)

type RolePolicyStatement added in v1.2.0

type RolePolicyStatement struct {
	Effect    Effect
	Action    string
	Principal Principal
}

type Tag

type Tag struct {
	Key   string
	Value string
}

Source Files

Jump to

Keyboard shortcuts

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