Versions in this module Expand all Collapse all v1 v1.0.2 Mar 29, 2023 v1.0.1 May 13, 2022 v1.0.0 Jun 15, 2021 v0 v0.0.1 Apr 21, 2021 Changes in this version + const BootDiskStateNormal + const DefaultCreateImageTimeout + const DefaultPasswordNum + const DefaultPasswordSpe + const DefaultPasswordStr + const ImageStateAvailable + const ImageStateUnavailable + const InstanceStateRunning + const InstanceStateStopped + const IpTypePrivate + const OsTypeWindows + const SecurityGroupNonWeb + var BootDiskTypeMap = NewStringConverter(map[string]string{ ... }) + var ChargeModeMap = NewStringConverter(map[string]string{ ... }) + var ImageNamePattern = regexp.MustCompile(`^[A-Za-z0-9\p{Han}-_\[\]:,.]{1,63}$`) + var UcloudPluginVersion *version.PluginVersion + func CheckIntIn(val int, available []int) error + func CheckStringIn(val string, available []string) error + func Halt(state multistep.StateBag, err error, prefix string) multistep.StepAction + func IsExpectedStateError(err error) bool + func IsNotCompleteError(err error) bool + func IsNotFoundError(err error) bool + func IsStringIn(val string, available []string) bool + func NewExpectedStateError(product, id string) error + func NewNotCompletedError(product string) error + func NewNotFoundError(product, id string) error + func NewStringConverter(input map[string]string) stringConverter + func SSHHost(usePrivateIp bool) func(multistep.StateBag) (string, error) + type AccessConfig struct + BaseUrl string + PrivateKey string + Profile string + ProjectId string + PublicKey string + Region string + SharedCredentialsFile string + func (c *AccessConfig) Client() (*UCloudClient, error) + func (c *AccessConfig) Config() error + func (c *AccessConfig) Prepare(ctx *interpolate.Context) []error + func (c *AccessConfig) ValidateProjectId(projectId string) error + func (c *AccessConfig) ValidateRegion(region string) error + func (c *AccessConfig) ValidateZone(region, zone string) error + type Artifact struct + BuilderIdValue string + Client *UCloudClient + StateData map[string]interface{} + UCloudImages *ImageInfoSet + func (*Artifact) Files() []string + func (a *Artifact) BuilderId() string + func (a *Artifact) Destroy() error + func (a *Artifact) Id() string + func (a *Artifact) State(name string) interface{} + func (a *Artifact) String() string + type ExpectedStateError struct + func (e *ExpectedStateError) Error() string + type FlatImageDestination struct + Description *string + Name *string + ProjectId *string + Region *string + func (*FlatImageDestination) HCL2Spec() map[string]hcldec.Spec + type ImageConfig struct + ImageDescription string + ImageDestinations []ImageDestination + ImageName string + WaitImageReadyTimeout int + func (c *ImageConfig) Prepare(ctx *interpolate.Context) []error + type ImageDestination struct + Description string + Name string + ProjectId string + Region string + func (*ImageDestination) FlatMapstructure() interface{ ... } + type ImageInfo struct + ImageId string + ProjectId string + Region string + func (i *ImageInfo) Id() string + type ImageInfoSet struct + func NewImageInfoSet(vL []ImageInfo) *ImageInfoSet + func (i *ImageInfoSet) Get(projectId, region string) *ImageInfo + func (i *ImageInfoSet) GetAll() []ImageInfo + func (i *ImageInfoSet) Remove(id string) + func (i *ImageInfoSet) Set(img ImageInfo) + type InstanceType struct + CPU int + HostScaleType string + HostType string + Memory int + func ParseInstanceType(s string) (*InstanceType, error) + func (i *InstanceType) Iscustomized() bool + func (i *InstanceType) String() string + type NotCompletedError struct + func (e *NotCompletedError) Error() string + type NotFoundError struct + func (e *NotFoundError) Error() string + type RunConfig struct + BootDiskType string + Comm communicator.Config + EipBandwidth int + EipChargeMode string + InstanceName string + InstanceType string + MinCpuPlatform string + SecurityGroupId string + SourceImageId string + SubnetId string + UseSSHPrivateIp bool + UserData string + UserDataFile string + VPCId string + Zone string + func (c *RunConfig) Prepare(ctx *interpolate.Context) []error + type UCloudClient struct + UAccountConn *uaccount.UAccountClient + UFileConn *ufile.UFileClient + UHostConn *uhost.UHostClient + UNetConn *unet.UNetClient + VPCConn *vpc.VPCClient + func (c *UCloudClient) DescribeFirewallById(sgId string) (*unet.FirewallDataSet, error) + func (c *UCloudClient) DescribeImageById(imageId string) (*uhost.UHostImageSet, error) + func (c *UCloudClient) DescribeImageByInfo(projectId, regionId, imageId string) (*uhost.UHostImageSet, error) + func (c *UCloudClient) DescribeSubnetById(subnetId string) (*vpc.VPCSubnetInfoSet, error) + func (c *UCloudClient) DescribeUHostById(uhostId string) (*uhost.UHostInstanceSet, error) + func (c *UCloudClient) DescribeVPCById(vpcId string) (*vpc.VPCInfo, error)