1. Packages
  2. Ucloud Provider
  3. API Docs
  4. Instance
ucloud 1.39.1 published on Monday, Apr 14, 2025 by ucloud

ucloud.Instance

Explore with Pulumi AI

ucloud logo
ucloud 1.39.1 published on Monday, Apr 14, 2025 by ucloud

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as ucloud from "@pulumi/ucloud";
    
    const _default = ucloud.getSecurityGroups({
        type: "recommend_web",
    });
    const normalImages = ucloud.getImages({
        availabilityZone: "cn-bj2-03",
        nameRegex: "^CentOS 6.5 64",
        imageType: "base",
    });
    // Create normal instance
    const normalInstance = new ucloud.Instance("normalInstance", {
        availabilityZone: "cn-bj2-03",
        imageId: normalImages.then(normalImages => normalImages.images?.[0]?.id),
        instanceType: "n-basic-2",
        rootPassword: "wA1234567",
        tag: "tf-example",
        bootDiskType: "cloud_ssd",
        securityGroup: _default.then(_default => _default.securityGroups?.[0]?.id),
        dataDisks: {
            size: 20,
            type: "cloud_ssd",
        },
        deleteDisksWithInstance: true,
    });
    const outstandingImages = ucloud.getImages({
        availabilityZone: "cn-bj2-03",
        nameRegex: "^高内核CentOS 7.6 64",
        imageType: "base",
    });
    // Create outstanding instance
    const outstandingInstance = new ucloud.Instance("outstandingInstance", {
        availabilityZone: "cn-bj2-03",
        imageId: outstandingImages.then(outstandingImages => outstandingImages.images?.[0]?.id),
        instanceType: "o-basic-4",
        rootPassword: "wA1234567",
        tag: "tf-example",
        bootDiskType: "cloud_rssd",
        securityGroup: _default.then(_default => _default.securityGroups?.[0]?.id),
        dataDisks: {
            size: 20,
            type: "cloud_rssd",
        },
        deleteDisksWithInstance: true,
    });
    
    import pulumi
    import pulumi_ucloud as ucloud
    
    default = ucloud.get_security_groups(type="recommend_web")
    normal_images = ucloud.get_images(availability_zone="cn-bj2-03",
        name_regex="^CentOS 6.5 64",
        image_type="base")
    # Create normal instance
    normal_instance = ucloud.Instance("normalInstance",
        availability_zone="cn-bj2-03",
        image_id=normal_images.images[0].id,
        instance_type="n-basic-2",
        root_password="wA1234567",
        tag="tf-example",
        boot_disk_type="cloud_ssd",
        security_group=default.security_groups[0].id,
        data_disks={
            "size": 20,
            "type": "cloud_ssd",
        },
        delete_disks_with_instance=True)
    outstanding_images = ucloud.get_images(availability_zone="cn-bj2-03",
        name_regex="^高内核CentOS 7.6 64",
        image_type="base")
    # Create outstanding instance
    outstanding_instance = ucloud.Instance("outstandingInstance",
        availability_zone="cn-bj2-03",
        image_id=outstanding_images.images[0].id,
        instance_type="o-basic-4",
        root_password="wA1234567",
        tag="tf-example",
        boot_disk_type="cloud_rssd",
        security_group=default.security_groups[0].id,
        data_disks={
            "size": 20,
            "type": "cloud_rssd",
        },
        delete_disks_with_instance=True)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/ucloud/ucloud"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_default, err := ucloud.GetSecurityGroups(ctx, &ucloud.GetSecurityGroupsArgs{
    			Type: pulumi.StringRef("recommend_web"),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		normalImages, err := ucloud.GetImages(ctx, &ucloud.GetImagesArgs{
    			AvailabilityZone: pulumi.StringRef("cn-bj2-03"),
    			NameRegex:        pulumi.StringRef("^CentOS 6.5 64"),
    			ImageType:        pulumi.StringRef("base"),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		// Create normal instance
    		_, err = ucloud.NewInstance(ctx, "normalInstance", &ucloud.InstanceArgs{
    			AvailabilityZone: pulumi.String("cn-bj2-03"),
    			ImageId:          pulumi.String(normalImages.Images[0].Id),
    			InstanceType:     pulumi.String("n-basic-2"),
    			RootPassword:     pulumi.String("wA1234567"),
    			Tag:              pulumi.String("tf-example"),
    			BootDiskType:     pulumi.String("cloud_ssd"),
    			SecurityGroup:    pulumi.String(_default.SecurityGroups[0].Id),
    			DataDisks: &ucloud.InstanceDataDisksArgs{
    				Size: pulumi.Float64(20),
    				Type: pulumi.String("cloud_ssd"),
    			},
    			DeleteDisksWithInstance: pulumi.Bool(true),
    		})
    		if err != nil {
    			return err
    		}
    		outstandingImages, err := ucloud.GetImages(ctx, &ucloud.GetImagesArgs{
    			AvailabilityZone: pulumi.StringRef("cn-bj2-03"),
    			NameRegex:        pulumi.StringRef("^高内核CentOS 7.6 64"),
    			ImageType:        pulumi.StringRef("base"),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		// Create outstanding instance
    		_, err = ucloud.NewInstance(ctx, "outstandingInstance", &ucloud.InstanceArgs{
    			AvailabilityZone: pulumi.String("cn-bj2-03"),
    			ImageId:          pulumi.String(outstandingImages.Images[0].Id),
    			InstanceType:     pulumi.String("o-basic-4"),
    			RootPassword:     pulumi.String("wA1234567"),
    			Tag:              pulumi.String("tf-example"),
    			BootDiskType:     pulumi.String("cloud_rssd"),
    			SecurityGroup:    pulumi.String(_default.SecurityGroups[0].Id),
    			DataDisks: &ucloud.InstanceDataDisksArgs{
    				Size: pulumi.Float64(20),
    				Type: pulumi.String("cloud_rssd"),
    			},
    			DeleteDisksWithInstance: pulumi.Bool(true),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Ucloud = Pulumi.Ucloud;
    
    return await Deployment.RunAsync(() => 
    {
        var @default = Ucloud.GetSecurityGroups.Invoke(new()
        {
            Type = "recommend_web",
        });
    
        var normalImages = Ucloud.GetImages.Invoke(new()
        {
            AvailabilityZone = "cn-bj2-03",
            NameRegex = "^CentOS 6.5 64",
            ImageType = "base",
        });
    
        // Create normal instance
        var normalInstance = new Ucloud.Instance("normalInstance", new()
        {
            AvailabilityZone = "cn-bj2-03",
            ImageId = normalImages.Apply(getImagesResult => getImagesResult.Images[0]?.Id),
            InstanceType = "n-basic-2",
            RootPassword = "wA1234567",
            Tag = "tf-example",
            BootDiskType = "cloud_ssd",
            SecurityGroup = @default.Apply(@default => @default.Apply(getSecurityGroupsResult => getSecurityGroupsResult.SecurityGroups[0]?.Id)),
            DataDisks = new Ucloud.Inputs.InstanceDataDisksArgs
            {
                Size = 20,
                Type = "cloud_ssd",
            },
            DeleteDisksWithInstance = true,
        });
    
        var outstandingImages = Ucloud.GetImages.Invoke(new()
        {
            AvailabilityZone = "cn-bj2-03",
            NameRegex = "^高内核CentOS 7.6 64",
            ImageType = "base",
        });
    
        // Create outstanding instance
        var outstandingInstance = new Ucloud.Instance("outstandingInstance", new()
        {
            AvailabilityZone = "cn-bj2-03",
            ImageId = outstandingImages.Apply(getImagesResult => getImagesResult.Images[0]?.Id),
            InstanceType = "o-basic-4",
            RootPassword = "wA1234567",
            Tag = "tf-example",
            BootDiskType = "cloud_rssd",
            SecurityGroup = @default.Apply(@default => @default.Apply(getSecurityGroupsResult => getSecurityGroupsResult.SecurityGroups[0]?.Id)),
            DataDisks = new Ucloud.Inputs.InstanceDataDisksArgs
            {
                Size = 20,
                Type = "cloud_rssd",
            },
            DeleteDisksWithInstance = true,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.ucloud.UcloudFunctions;
    import com.pulumi.ucloud.inputs.GetSecurityGroupsArgs;
    import com.pulumi.ucloud.inputs.GetImagesArgs;
    import com.pulumi.ucloud.Instance;
    import com.pulumi.ucloud.InstanceArgs;
    import com.pulumi.ucloud.inputs.InstanceDataDisksArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            final var default = UcloudFunctions.getSecurityGroups(GetSecurityGroupsArgs.builder()
                .type("recommend_web")
                .build());
    
            final var normalImages = UcloudFunctions.getImages(GetImagesArgs.builder()
                .availabilityZone("cn-bj2-03")
                .nameRegex("^CentOS 6.5 64")
                .imageType("base")
                .build());
    
            // Create normal instance
            var normalInstance = new Instance("normalInstance", InstanceArgs.builder()
                .availabilityZone("cn-bj2-03")
                .imageId(normalImages.applyValue(getImagesResult -> getImagesResult.images()[0].id()))
                .instanceType("n-basic-2")
                .rootPassword("wA1234567")
                .tag("tf-example")
                .bootDiskType("cloud_ssd")
                .securityGroup(default_.securityGroups()[0].id())
                .dataDisks(InstanceDataDisksArgs.builder()
                    .size(20)
                    .type("cloud_ssd")
                    .build())
                .deleteDisksWithInstance(true)
                .build());
    
            final var outstandingImages = UcloudFunctions.getImages(GetImagesArgs.builder()
                .availabilityZone("cn-bj2-03")
                .nameRegex("^高内核CentOS 7.6 64")
                .imageType("base")
                .build());
    
            // Create outstanding instance
            var outstandingInstance = new Instance("outstandingInstance", InstanceArgs.builder()
                .availabilityZone("cn-bj2-03")
                .imageId(outstandingImages.applyValue(getImagesResult -> getImagesResult.images()[0].id()))
                .instanceType("o-basic-4")
                .rootPassword("wA1234567")
                .tag("tf-example")
                .bootDiskType("cloud_rssd")
                .securityGroup(default_.securityGroups()[0].id())
                .dataDisks(InstanceDataDisksArgs.builder()
                    .size(20)
                    .type("cloud_rssd")
                    .build())
                .deleteDisksWithInstance(true)
                .build());
    
        }
    }
    
    resources:
      # Create normal instance
      normalInstance:
        type: ucloud:Instance
        properties:
          availabilityZone: cn-bj2-03
          imageId: ${normalImages.images[0].id}
          instanceType: n-basic-2
          rootPassword: wA1234567
          tag: tf-example
          bootDiskType: cloud_ssd
          # the default Web Security Group that UCloud recommend to users
          securityGroup: ${default.securityGroups[0].id}
          dataDisks:
            size: 20
            type: cloud_ssd
          deleteDisksWithInstance: true
      # Create outstanding instance
      outstandingInstance:
        type: ucloud:Instance
        properties:
          availabilityZone: cn-bj2-03
          imageId: ${outstandingImages.images[0].id}
          instanceType: o-basic-4
          rootPassword: wA1234567
          tag: tf-example
          bootDiskType: cloud_rssd
          # the default Web Security Group that UCloud recommend to users
          securityGroup: ${default.securityGroups[0].id}
          dataDisks:
            size: 20
            type: cloud_rssd
          deleteDisksWithInstance: true
    variables:
      default:
        fn::invoke:
          function: ucloud:getSecurityGroups
          arguments:
            type: recommend_web
      normalImages:
        fn::invoke:
          function: ucloud:getImages
          arguments:
            availabilityZone: cn-bj2-03
            nameRegex: ^CentOS 6.5 64
            imageType: base
      outstandingImages:
        fn::invoke:
          function: ucloud:getImages
          arguments:
            availabilityZone: cn-bj2-03
            nameRegex: ^高内核CentOS 7.6 64
            imageType: base
    

    Create Instance Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new Instance(name: string, args: InstanceArgs, opts?: CustomResourceOptions);
    @overload
    def Instance(resource_name: str,
                 args: InstanceArgs,
                 opts: Optional[ResourceOptions] = None)
    
    @overload
    def Instance(resource_name: str,
                 opts: Optional[ResourceOptions] = None,
                 image_id: Optional[str] = None,
                 availability_zone: Optional[str] = None,
                 instance_type: Optional[str] = None,
                 instance_id: Optional[str] = None,
                 isolation_group: Optional[str] = None,
                 data_disk_size: Optional[float] = None,
                 data_disk_type: Optional[str] = None,
                 data_disks: Optional[InstanceDataDisksArgs] = None,
                 delete_disks_with_instance: Optional[bool] = None,
                 delete_eips_with_instance: Optional[bool] = None,
                 duration: Optional[float] = None,
                 boot_disk_type: Optional[str] = None,
                 allow_stopping_for_update: Optional[bool] = None,
                 boot_disk_size: Optional[float] = None,
                 charge_type: Optional[str] = None,
                 min_cpu_platform: Optional[str] = None,
                 name: Optional[str] = None,
                 network_interface: Optional[InstanceNetworkInterfaceArgs] = None,
                 private_ip: Optional[str] = None,
                 remark: Optional[str] = None,
                 root_password: Optional[str] = None,
                 security_group: Optional[str] = None,
                 subnet_id: Optional[str] = None,
                 tag: Optional[str] = None,
                 timeouts: Optional[InstanceTimeoutsArgs] = None,
                 user_data: Optional[str] = None,
                 vpc_id: Optional[str] = None)
    func NewInstance(ctx *Context, name string, args InstanceArgs, opts ...ResourceOption) (*Instance, error)
    public Instance(string name, InstanceArgs args, CustomResourceOptions? opts = null)
    public Instance(String name, InstanceArgs args)
    public Instance(String name, InstanceArgs args, CustomResourceOptions options)
    
    type: ucloud:Instance
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args InstanceArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args InstanceArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args InstanceArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args InstanceArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args InstanceArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var instanceResource = new Ucloud.Instance("instanceResource", new()
    {
        ImageId = "string",
        AvailabilityZone = "string",
        InstanceType = "string",
        InstanceId = "string",
        IsolationGroup = "string",
        DataDiskSize = 0,
        DataDiskType = "string",
        DataDisks = new Ucloud.Inputs.InstanceDataDisksArgs
        {
            Size = 0,
            Type = "string",
        },
        DeleteDisksWithInstance = false,
        DeleteEipsWithInstance = false,
        Duration = 0,
        BootDiskType = "string",
        AllowStoppingForUpdate = false,
        BootDiskSize = 0,
        ChargeType = "string",
        MinCpuPlatform = "string",
        Name = "string",
        NetworkInterface = new Ucloud.Inputs.InstanceNetworkInterfaceArgs
        {
            EipBandwidth = 0,
            EipChargeMode = "string",
            EipInternetType = "string",
        },
        PrivateIp = "string",
        Remark = "string",
        RootPassword = "string",
        SecurityGroup = "string",
        SubnetId = "string",
        Tag = "string",
        Timeouts = new Ucloud.Inputs.InstanceTimeoutsArgs
        {
            Create = "string",
            Delete = "string",
            Update = "string",
        },
        UserData = "string",
        VpcId = "string",
    });
    
    example, err := ucloud.NewInstance(ctx, "instanceResource", &ucloud.InstanceArgs{
    	ImageId:          pulumi.String("string"),
    	AvailabilityZone: pulumi.String("string"),
    	InstanceType:     pulumi.String("string"),
    	InstanceId:       pulumi.String("string"),
    	IsolationGroup:   pulumi.String("string"),
    	DataDiskSize:     pulumi.Float64(0),
    	DataDiskType:     pulumi.String("string"),
    	DataDisks: &ucloud.InstanceDataDisksArgs{
    		Size: pulumi.Float64(0),
    		Type: pulumi.String("string"),
    	},
    	DeleteDisksWithInstance: pulumi.Bool(false),
    	DeleteEipsWithInstance:  pulumi.Bool(false),
    	Duration:                pulumi.Float64(0),
    	BootDiskType:            pulumi.String("string"),
    	AllowStoppingForUpdate:  pulumi.Bool(false),
    	BootDiskSize:            pulumi.Float64(0),
    	ChargeType:              pulumi.String("string"),
    	MinCpuPlatform:          pulumi.String("string"),
    	Name:                    pulumi.String("string"),
    	NetworkInterface: &ucloud.InstanceNetworkInterfaceArgs{
    		EipBandwidth:    pulumi.Float64(0),
    		EipChargeMode:   pulumi.String("string"),
    		EipInternetType: pulumi.String("string"),
    	},
    	PrivateIp:     pulumi.String("string"),
    	Remark:        pulumi.String("string"),
    	RootPassword:  pulumi.String("string"),
    	SecurityGroup: pulumi.String("string"),
    	SubnetId:      pulumi.String("string"),
    	Tag:           pulumi.String("string"),
    	Timeouts: &ucloud.InstanceTimeoutsArgs{
    		Create: pulumi.String("string"),
    		Delete: pulumi.String("string"),
    		Update: pulumi.String("string"),
    	},
    	UserData: pulumi.String("string"),
    	VpcId:    pulumi.String("string"),
    })
    
    var instanceResource = new Instance("instanceResource", InstanceArgs.builder()
        .imageId("string")
        .availabilityZone("string")
        .instanceType("string")
        .instanceId("string")
        .isolationGroup("string")
        .dataDiskSize(0)
        .dataDiskType("string")
        .dataDisks(InstanceDataDisksArgs.builder()
            .size(0)
            .type("string")
            .build())
        .deleteDisksWithInstance(false)
        .deleteEipsWithInstance(false)
        .duration(0)
        .bootDiskType("string")
        .allowStoppingForUpdate(false)
        .bootDiskSize(0)
        .chargeType("string")
        .minCpuPlatform("string")
        .name("string")
        .networkInterface(InstanceNetworkInterfaceArgs.builder()
            .eipBandwidth(0)
            .eipChargeMode("string")
            .eipInternetType("string")
            .build())
        .privateIp("string")
        .remark("string")
        .rootPassword("string")
        .securityGroup("string")
        .subnetId("string")
        .tag("string")
        .timeouts(InstanceTimeoutsArgs.builder()
            .create("string")
            .delete("string")
            .update("string")
            .build())
        .userData("string")
        .vpcId("string")
        .build());
    
    instance_resource = ucloud.Instance("instanceResource",
        image_id="string",
        availability_zone="string",
        instance_type="string",
        instance_id="string",
        isolation_group="string",
        data_disk_size=0,
        data_disk_type="string",
        data_disks={
            "size": 0,
            "type": "string",
        },
        delete_disks_with_instance=False,
        delete_eips_with_instance=False,
        duration=0,
        boot_disk_type="string",
        allow_stopping_for_update=False,
        boot_disk_size=0,
        charge_type="string",
        min_cpu_platform="string",
        name="string",
        network_interface={
            "eip_bandwidth": 0,
            "eip_charge_mode": "string",
            "eip_internet_type": "string",
        },
        private_ip="string",
        remark="string",
        root_password="string",
        security_group="string",
        subnet_id="string",
        tag="string",
        timeouts={
            "create": "string",
            "delete": "string",
            "update": "string",
        },
        user_data="string",
        vpc_id="string")
    
    const instanceResource = new ucloud.Instance("instanceResource", {
        imageId: "string",
        availabilityZone: "string",
        instanceType: "string",
        instanceId: "string",
        isolationGroup: "string",
        dataDiskSize: 0,
        dataDiskType: "string",
        dataDisks: {
            size: 0,
            type: "string",
        },
        deleteDisksWithInstance: false,
        deleteEipsWithInstance: false,
        duration: 0,
        bootDiskType: "string",
        allowStoppingForUpdate: false,
        bootDiskSize: 0,
        chargeType: "string",
        minCpuPlatform: "string",
        name: "string",
        networkInterface: {
            eipBandwidth: 0,
            eipChargeMode: "string",
            eipInternetType: "string",
        },
        privateIp: "string",
        remark: "string",
        rootPassword: "string",
        securityGroup: "string",
        subnetId: "string",
        tag: "string",
        timeouts: {
            create: "string",
            "delete": "string",
            update: "string",
        },
        userData: "string",
        vpcId: "string",
    });
    
    type: ucloud:Instance
    properties:
        allowStoppingForUpdate: false
        availabilityZone: string
        bootDiskSize: 0
        bootDiskType: string
        chargeType: string
        dataDiskSize: 0
        dataDiskType: string
        dataDisks:
            size: 0
            type: string
        deleteDisksWithInstance: false
        deleteEipsWithInstance: false
        duration: 0
        imageId: string
        instanceId: string
        instanceType: string
        isolationGroup: string
        minCpuPlatform: string
        name: string
        networkInterface:
            eipBandwidth: 0
            eipChargeMode: string
            eipInternetType: string
        privateIp: string
        remark: string
        rootPassword: string
        securityGroup: string
        subnetId: string
        tag: string
        timeouts:
            create: string
            delete: string
            update: string
        userData: string
        vpcId: string
    

    Instance Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The Instance resource accepts the following input properties:

    AvailabilityZone string
    Availability zone where instance is located. such as: cn-bj2-02. You may refer to list of availability zone
    ImageId string
    The ID for the image to use for the instance.
    InstanceType string

    The type of instance, please visit the instance type table

    Note If you want to update this value, you must set allow_stopping_for_updateto true.


    AllowStoppingForUpdate bool
    BootDiskSize double

    The size of the boot disk, measured in GB (GigaByte). Range: 20-500. The value set of disk size must be larger or equal to 20(default: 20) for Linux and 40 (default: 40) for Windows. The responsive time is a bit longer if the value set is larger than default for local boot disk, and further settings may be required on host instance if the value set is larger than default for cloud boot disk. The disk volume adjustment must be a multiple of 10 GB. In addition, any reduction of boot disk size is not supported.

    Note If you want to update this value, you must set allow_stopping_for_updateto true. In addition, when it is changed, you need to go to the instance for configuration.

    BootDiskType string
    The type of boot disk. Possible values are: local_normal and local_ssd for local boot disk, cloud_ssd for cloud SSD boot disk,rssd_data_disk as RDMA-SSD cloud disk. (Default: local_normal). The local_ssd and cloud_ssd are not fully support by all regions as boot disk type, please proceed to UCloud console for more details.
    ChargeType string
    The charge type of instance, possible values are: year, month and dynamic as pay by hour (specific permission required). (Default: month).
    DataDiskSize double

    The size of local data disk, measured in GB (GigaByte), 20-2000 for local sata disk and 20-1000 for local ssd disk (all the GPU type instances are included). The volume adjustment must be a multiple of 10 GB. In addition, any reduction of data disk size is not supported.

    Note If you want to update this value, you must set allow_stopping_for_updateto true. In addition, when it is changed, you need to go to the instance for configuration.

    DataDiskType string
    The type of local data disk. Possible values are: local_normal and local_ssd for local data disk. (Default: local_normal). The local_ssd is not fully support by all regions as data disk type, please proceed to UCloud console for more details. In addition, the data_disk_type must be same as boot_disk_type if specified.
    DataDisks InstanceDataDisks
    Additional cloud data disks to attach to the instance. data_disks configurations only apply on resource creation. The count of data_disks can only be one. See data_disks below for details on attributes. When set data_disks, the argument delete_disks_with_instance must bet set.
    DeleteDisksWithInstance bool
    DeleteEipsWithInstance bool
    Duration double
    The duration that you will buy the instance (Default: 1). The value is 0 when pay by month and the instance will be valid till the last day of that month. It is not required when dynamic (pay by hour).
    InstanceId string
    The ID of disk.
    IsolationGroup string
    The ID of the associated isolation group.
    MinCpuPlatform string
    Specifies a minimum CPU platform for the the VM instance. (Default: Intel/Auto). You may refer to product documentation and API documentation.
    Name string
    NetworkInterface InstanceNetworkInterface
    PrivateIp string
    The private IP address assigned to the instance.
    Remark string
    The remarks of instance. (Default: "").
    RootPassword string
    SecurityGroup string
    The ID of the associated security group.
    SubnetId string
    The ID of subnet. If defined vpc_id, the subnet_id is Required. If not defined vpc_id and subnet_id, the instance will use the default subnet in the current region.
    Tag string
    A tag assigned to instance, which contains at most 63 characters and only support Chinese, English, numbers, '-', '_', and '.'. If it is not filled in or a empty string is filled in, then default tag will be assigned. (Default: Default).
    Timeouts InstanceTimeouts
    UserData string
    The user data to customize the startup behaviors when launching the instance. You may refer to user_data_document
    VpcId string
    The ID of VPC linked to the instance. If not defined vpc_id, the instance will use the default VPC in the current region.
    AvailabilityZone string
    Availability zone where instance is located. such as: cn-bj2-02. You may refer to list of availability zone
    ImageId string
    The ID for the image to use for the instance.
    InstanceType string

    The type of instance, please visit the instance type table

    Note If you want to update this value, you must set allow_stopping_for_updateto true.


    AllowStoppingForUpdate bool
    BootDiskSize float64

    The size of the boot disk, measured in GB (GigaByte). Range: 20-500. The value set of disk size must be larger or equal to 20(default: 20) for Linux and 40 (default: 40) for Windows. The responsive time is a bit longer if the value set is larger than default for local boot disk, and further settings may be required on host instance if the value set is larger than default for cloud boot disk. The disk volume adjustment must be a multiple of 10 GB. In addition, any reduction of boot disk size is not supported.

    Note If you want to update this value, you must set allow_stopping_for_updateto true. In addition, when it is changed, you need to go to the instance for configuration.

    BootDiskType string
    The type of boot disk. Possible values are: local_normal and local_ssd for local boot disk, cloud_ssd for cloud SSD boot disk,rssd_data_disk as RDMA-SSD cloud disk. (Default: local_normal). The local_ssd and cloud_ssd are not fully support by all regions as boot disk type, please proceed to UCloud console for more details.
    ChargeType string
    The charge type of instance, possible values are: year, month and dynamic as pay by hour (specific permission required). (Default: month).
    DataDiskSize float64

    The size of local data disk, measured in GB (GigaByte), 20-2000 for local sata disk and 20-1000 for local ssd disk (all the GPU type instances are included). The volume adjustment must be a multiple of 10 GB. In addition, any reduction of data disk size is not supported.

    Note If you want to update this value, you must set allow_stopping_for_updateto true. In addition, when it is changed, you need to go to the instance for configuration.

    DataDiskType string
    The type of local data disk. Possible values are: local_normal and local_ssd for local data disk. (Default: local_normal). The local_ssd is not fully support by all regions as data disk type, please proceed to UCloud console for more details. In addition, the data_disk_type must be same as boot_disk_type if specified.
    DataDisks InstanceDataDisksArgs
    Additional cloud data disks to attach to the instance. data_disks configurations only apply on resource creation. The count of data_disks can only be one. See data_disks below for details on attributes. When set data_disks, the argument delete_disks_with_instance must bet set.
    DeleteDisksWithInstance bool
    DeleteEipsWithInstance bool
    Duration float64
    The duration that you will buy the instance (Default: 1). The value is 0 when pay by month and the instance will be valid till the last day of that month. It is not required when dynamic (pay by hour).
    InstanceId string
    The ID of disk.
    IsolationGroup string
    The ID of the associated isolation group.
    MinCpuPlatform string
    Specifies a minimum CPU platform for the the VM instance. (Default: Intel/Auto). You may refer to product documentation and API documentation.
    Name string
    NetworkInterface InstanceNetworkInterfaceArgs
    PrivateIp string
    The private IP address assigned to the instance.
    Remark string
    The remarks of instance. (Default: "").
    RootPassword string
    SecurityGroup string
    The ID of the associated security group.
    SubnetId string
    The ID of subnet. If defined vpc_id, the subnet_id is Required. If not defined vpc_id and subnet_id, the instance will use the default subnet in the current region.
    Tag string
    A tag assigned to instance, which contains at most 63 characters and only support Chinese, English, numbers, '-', '_', and '.'. If it is not filled in or a empty string is filled in, then default tag will be assigned. (Default: Default).
    Timeouts InstanceTimeoutsArgs
    UserData string
    The user data to customize the startup behaviors when launching the instance. You may refer to user_data_document
    VpcId string
    The ID of VPC linked to the instance. If not defined vpc_id, the instance will use the default VPC in the current region.
    availabilityZone String
    Availability zone where instance is located. such as: cn-bj2-02. You may refer to list of availability zone
    imageId String
    The ID for the image to use for the instance.
    instanceType String

    The type of instance, please visit the instance type table

    Note If you want to update this value, you must set allow_stopping_for_updateto true.


    allowStoppingForUpdate Boolean
    bootDiskSize Double

    The size of the boot disk, measured in GB (GigaByte). Range: 20-500. The value set of disk size must be larger or equal to 20(default: 20) for Linux and 40 (default: 40) for Windows. The responsive time is a bit longer if the value set is larger than default for local boot disk, and further settings may be required on host instance if the value set is larger than default for cloud boot disk. The disk volume adjustment must be a multiple of 10 GB. In addition, any reduction of boot disk size is not supported.

    Note If you want to update this value, you must set allow_stopping_for_updateto true. In addition, when it is changed, you need to go to the instance for configuration.

    bootDiskType String
    The type of boot disk. Possible values are: local_normal and local_ssd for local boot disk, cloud_ssd for cloud SSD boot disk,rssd_data_disk as RDMA-SSD cloud disk. (Default: local_normal). The local_ssd and cloud_ssd are not fully support by all regions as boot disk type, please proceed to UCloud console for more details.
    chargeType String
    The charge type of instance, possible values are: year, month and dynamic as pay by hour (specific permission required). (Default: month).
    dataDiskSize Double

    The size of local data disk, measured in GB (GigaByte), 20-2000 for local sata disk and 20-1000 for local ssd disk (all the GPU type instances are included). The volume adjustment must be a multiple of 10 GB. In addition, any reduction of data disk size is not supported.

    Note If you want to update this value, you must set allow_stopping_for_updateto true. In addition, when it is changed, you need to go to the instance for configuration.

    dataDiskType String
    The type of local data disk. Possible values are: local_normal and local_ssd for local data disk. (Default: local_normal). The local_ssd is not fully support by all regions as data disk type, please proceed to UCloud console for more details. In addition, the data_disk_type must be same as boot_disk_type if specified.
    dataDisks InstanceDataDisks
    Additional cloud data disks to attach to the instance. data_disks configurations only apply on resource creation. The count of data_disks can only be one. See data_disks below for details on attributes. When set data_disks, the argument delete_disks_with_instance must bet set.
    deleteDisksWithInstance Boolean
    deleteEipsWithInstance Boolean
    duration Double
    The duration that you will buy the instance (Default: 1). The value is 0 when pay by month and the instance will be valid till the last day of that month. It is not required when dynamic (pay by hour).
    instanceId String
    The ID of disk.
    isolationGroup String
    The ID of the associated isolation group.
    minCpuPlatform String
    Specifies a minimum CPU platform for the the VM instance. (Default: Intel/Auto). You may refer to product documentation and API documentation.
    name String
    networkInterface InstanceNetworkInterface
    privateIp String
    The private IP address assigned to the instance.
    remark String
    The remarks of instance. (Default: "").
    rootPassword String
    securityGroup String
    The ID of the associated security group.
    subnetId String
    The ID of subnet. If defined vpc_id, the subnet_id is Required. If not defined vpc_id and subnet_id, the instance will use the default subnet in the current region.
    tag String
    A tag assigned to instance, which contains at most 63 characters and only support Chinese, English, numbers, '-', '_', and '.'. If it is not filled in or a empty string is filled in, then default tag will be assigned. (Default: Default).
    timeouts InstanceTimeouts
    userData String
    The user data to customize the startup behaviors when launching the instance. You may refer to user_data_document
    vpcId String
    The ID of VPC linked to the instance. If not defined vpc_id, the instance will use the default VPC in the current region.
    availabilityZone string
    Availability zone where instance is located. such as: cn-bj2-02. You may refer to list of availability zone
    imageId string
    The ID for the image to use for the instance.
    instanceType string

    The type of instance, please visit the instance type table

    Note If you want to update this value, you must set allow_stopping_for_updateto true.


    allowStoppingForUpdate boolean
    bootDiskSize number

    The size of the boot disk, measured in GB (GigaByte). Range: 20-500. The value set of disk size must be larger or equal to 20(default: 20) for Linux and 40 (default: 40) for Windows. The responsive time is a bit longer if the value set is larger than default for local boot disk, and further settings may be required on host instance if the value set is larger than default for cloud boot disk. The disk volume adjustment must be a multiple of 10 GB. In addition, any reduction of boot disk size is not supported.

    Note If you want to update this value, you must set allow_stopping_for_updateto true. In addition, when it is changed, you need to go to the instance for configuration.

    bootDiskType string
    The type of boot disk. Possible values are: local_normal and local_ssd for local boot disk, cloud_ssd for cloud SSD boot disk,rssd_data_disk as RDMA-SSD cloud disk. (Default: local_normal). The local_ssd and cloud_ssd are not fully support by all regions as boot disk type, please proceed to UCloud console for more details.
    chargeType string
    The charge type of instance, possible values are: year, month and dynamic as pay by hour (specific permission required). (Default: month).
    dataDiskSize number

    The size of local data disk, measured in GB (GigaByte), 20-2000 for local sata disk and 20-1000 for local ssd disk (all the GPU type instances are included). The volume adjustment must be a multiple of 10 GB. In addition, any reduction of data disk size is not supported.

    Note If you want to update this value, you must set allow_stopping_for_updateto true. In addition, when it is changed, you need to go to the instance for configuration.

    dataDiskType string
    The type of local data disk. Possible values are: local_normal and local_ssd for local data disk. (Default: local_normal). The local_ssd is not fully support by all regions as data disk type, please proceed to UCloud console for more details. In addition, the data_disk_type must be same as boot_disk_type if specified.
    dataDisks InstanceDataDisks
    Additional cloud data disks to attach to the instance. data_disks configurations only apply on resource creation. The count of data_disks can only be one. See data_disks below for details on attributes. When set data_disks, the argument delete_disks_with_instance must bet set.
    deleteDisksWithInstance boolean
    deleteEipsWithInstance boolean
    duration number
    The duration that you will buy the instance (Default: 1). The value is 0 when pay by month and the instance will be valid till the last day of that month. It is not required when dynamic (pay by hour).
    instanceId string
    The ID of disk.
    isolationGroup string
    The ID of the associated isolation group.
    minCpuPlatform string
    Specifies a minimum CPU platform for the the VM instance. (Default: Intel/Auto). You may refer to product documentation and API documentation.
    name string
    networkInterface InstanceNetworkInterface
    privateIp string
    The private IP address assigned to the instance.
    remark string
    The remarks of instance. (Default: "").
    rootPassword string
    securityGroup string
    The ID of the associated security group.
    subnetId string
    The ID of subnet. If defined vpc_id, the subnet_id is Required. If not defined vpc_id and subnet_id, the instance will use the default subnet in the current region.
    tag string
    A tag assigned to instance, which contains at most 63 characters and only support Chinese, English, numbers, '-', '_', and '.'. If it is not filled in or a empty string is filled in, then default tag will be assigned. (Default: Default).
    timeouts InstanceTimeouts
    userData string
    The user data to customize the startup behaviors when launching the instance. You may refer to user_data_document
    vpcId string
    The ID of VPC linked to the instance. If not defined vpc_id, the instance will use the default VPC in the current region.
    availability_zone str
    Availability zone where instance is located. such as: cn-bj2-02. You may refer to list of availability zone
    image_id str
    The ID for the image to use for the instance.
    instance_type str

    The type of instance, please visit the instance type table

    Note If you want to update this value, you must set allow_stopping_for_updateto true.


    allow_stopping_for_update bool
    boot_disk_size float

    The size of the boot disk, measured in GB (GigaByte). Range: 20-500. The value set of disk size must be larger or equal to 20(default: 20) for Linux and 40 (default: 40) for Windows. The responsive time is a bit longer if the value set is larger than default for local boot disk, and further settings may be required on host instance if the value set is larger than default for cloud boot disk. The disk volume adjustment must be a multiple of 10 GB. In addition, any reduction of boot disk size is not supported.

    Note If you want to update this value, you must set allow_stopping_for_updateto true. In addition, when it is changed, you need to go to the instance for configuration.

    boot_disk_type str
    The type of boot disk. Possible values are: local_normal and local_ssd for local boot disk, cloud_ssd for cloud SSD boot disk,rssd_data_disk as RDMA-SSD cloud disk. (Default: local_normal). The local_ssd and cloud_ssd are not fully support by all regions as boot disk type, please proceed to UCloud console for more details.
    charge_type str
    The charge type of instance, possible values are: year, month and dynamic as pay by hour (specific permission required). (Default: month).
    data_disk_size float

    The size of local data disk, measured in GB (GigaByte), 20-2000 for local sata disk and 20-1000 for local ssd disk (all the GPU type instances are included). The volume adjustment must be a multiple of 10 GB. In addition, any reduction of data disk size is not supported.

    Note If you want to update this value, you must set allow_stopping_for_updateto true. In addition, when it is changed, you need to go to the instance for configuration.

    data_disk_type str
    The type of local data disk. Possible values are: local_normal and local_ssd for local data disk. (Default: local_normal). The local_ssd is not fully support by all regions as data disk type, please proceed to UCloud console for more details. In addition, the data_disk_type must be same as boot_disk_type if specified.
    data_disks InstanceDataDisksArgs
    Additional cloud data disks to attach to the instance. data_disks configurations only apply on resource creation. The count of data_disks can only be one. See data_disks below for details on attributes. When set data_disks, the argument delete_disks_with_instance must bet set.
    delete_disks_with_instance bool
    delete_eips_with_instance bool
    duration float
    The duration that you will buy the instance (Default: 1). The value is 0 when pay by month and the instance will be valid till the last day of that month. It is not required when dynamic (pay by hour).
    instance_id str
    The ID of disk.
    isolation_group str
    The ID of the associated isolation group.
    min_cpu_platform str
    Specifies a minimum CPU platform for the the VM instance. (Default: Intel/Auto). You may refer to product documentation and API documentation.
    name str
    network_interface InstanceNetworkInterfaceArgs
    private_ip str
    The private IP address assigned to the instance.
    remark str
    The remarks of instance. (Default: "").
    root_password str
    security_group str
    The ID of the associated security group.
    subnet_id str
    The ID of subnet. If defined vpc_id, the subnet_id is Required. If not defined vpc_id and subnet_id, the instance will use the default subnet in the current region.
    tag str
    A tag assigned to instance, which contains at most 63 characters and only support Chinese, English, numbers, '-', '_', and '.'. If it is not filled in or a empty string is filled in, then default tag will be assigned. (Default: Default).
    timeouts InstanceTimeoutsArgs
    user_data str
    The user data to customize the startup behaviors when launching the instance. You may refer to user_data_document
    vpc_id str
    The ID of VPC linked to the instance. If not defined vpc_id, the instance will use the default VPC in the current region.
    availabilityZone String
    Availability zone where instance is located. such as: cn-bj2-02. You may refer to list of availability zone
    imageId String
    The ID for the image to use for the instance.
    instanceType String

    The type of instance, please visit the instance type table

    Note If you want to update this value, you must set allow_stopping_for_updateto true.


    allowStoppingForUpdate Boolean
    bootDiskSize Number

    The size of the boot disk, measured in GB (GigaByte). Range: 20-500. The value set of disk size must be larger or equal to 20(default: 20) for Linux and 40 (default: 40) for Windows. The responsive time is a bit longer if the value set is larger than default for local boot disk, and further settings may be required on host instance if the value set is larger than default for cloud boot disk. The disk volume adjustment must be a multiple of 10 GB. In addition, any reduction of boot disk size is not supported.

    Note If you want to update this value, you must set allow_stopping_for_updateto true. In addition, when it is changed, you need to go to the instance for configuration.

    bootDiskType String
    The type of boot disk. Possible values are: local_normal and local_ssd for local boot disk, cloud_ssd for cloud SSD boot disk,rssd_data_disk as RDMA-SSD cloud disk. (Default: local_normal). The local_ssd and cloud_ssd are not fully support by all regions as boot disk type, please proceed to UCloud console for more details.
    chargeType String
    The charge type of instance, possible values are: year, month and dynamic as pay by hour (specific permission required). (Default: month).
    dataDiskSize Number

    The size of local data disk, measured in GB (GigaByte), 20-2000 for local sata disk and 20-1000 for local ssd disk (all the GPU type instances are included). The volume adjustment must be a multiple of 10 GB. In addition, any reduction of data disk size is not supported.

    Note If you want to update this value, you must set allow_stopping_for_updateto true. In addition, when it is changed, you need to go to the instance for configuration.

    dataDiskType String
    The type of local data disk. Possible values are: local_normal and local_ssd for local data disk. (Default: local_normal). The local_ssd is not fully support by all regions as data disk type, please proceed to UCloud console for more details. In addition, the data_disk_type must be same as boot_disk_type if specified.
    dataDisks Property Map
    Additional cloud data disks to attach to the instance. data_disks configurations only apply on resource creation. The count of data_disks can only be one. See data_disks below for details on attributes. When set data_disks, the argument delete_disks_with_instance must bet set.
    deleteDisksWithInstance Boolean
    deleteEipsWithInstance Boolean
    duration Number
    The duration that you will buy the instance (Default: 1). The value is 0 when pay by month and the instance will be valid till the last day of that month. It is not required when dynamic (pay by hour).
    instanceId String
    The ID of disk.
    isolationGroup String
    The ID of the associated isolation group.
    minCpuPlatform String
    Specifies a minimum CPU platform for the the VM instance. (Default: Intel/Auto). You may refer to product documentation and API documentation.
    name String
    networkInterface Property Map
    privateIp String
    The private IP address assigned to the instance.
    remark String
    The remarks of instance. (Default: "").
    rootPassword String
    securityGroup String
    The ID of the associated security group.
    subnetId String
    The ID of subnet. If defined vpc_id, the subnet_id is Required. If not defined vpc_id and subnet_id, the instance will use the default subnet in the current region.
    tag String
    A tag assigned to instance, which contains at most 63 characters and only support Chinese, English, numbers, '-', '_', and '.'. If it is not filled in or a empty string is filled in, then default tag will be assigned. (Default: Default).
    timeouts Property Map
    userData String
    The user data to customize the startup behaviors when launching the instance. You may refer to user_data_document
    vpcId String
    The ID of VPC linked to the instance. If not defined vpc_id, the instance will use the default VPC in the current region.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the Instance resource produces the following output properties:

    AutoRenew bool
    Whether to renew an instance automatically or not.
    Cpu double
    The number of cores of virtual CPU, measured in core.
    CpuPlatform string
    CreateTime string
    The time of creation for instance, formatted in RFC3339 time string.
    DiskSets List<InstanceDiskSet>
    It is a nested type which documented below.
    ExpireTime string
    The expiration time for instance, formatted in RFC3339 time string.
    Id string
    The provider-assigned unique ID for this managed resource.
    IpSets List<InstanceIpSet>
    It is a nested type which documented below.
    Memory double
    The size of memory, measured in GB(Gigabyte).
    RdmaClusterId string
    The RDMA Cluster ID of instance. This is only available when machine type is O.
    Status string
    Instance current status. Possible values are Initializing, Starting, Running, Stopping, Stopped, Install Fail, ResizeFail and Rebooting.
    AutoRenew bool
    Whether to renew an instance automatically or not.
    Cpu float64
    The number of cores of virtual CPU, measured in core.
    CpuPlatform string
    CreateTime string
    The time of creation for instance, formatted in RFC3339 time string.
    DiskSets []InstanceDiskSet
    It is a nested type which documented below.
    ExpireTime string
    The expiration time for instance, formatted in RFC3339 time string.
    Id string
    The provider-assigned unique ID for this managed resource.
    IpSets []InstanceIpSet
    It is a nested type which documented below.
    Memory float64
    The size of memory, measured in GB(Gigabyte).
    RdmaClusterId string
    The RDMA Cluster ID of instance. This is only available when machine type is O.
    Status string
    Instance current status. Possible values are Initializing, Starting, Running, Stopping, Stopped, Install Fail, ResizeFail and Rebooting.
    autoRenew Boolean
    Whether to renew an instance automatically or not.
    cpu Double
    The number of cores of virtual CPU, measured in core.
    cpuPlatform String
    createTime String
    The time of creation for instance, formatted in RFC3339 time string.
    diskSets List<InstanceDiskSet>
    It is a nested type which documented below.
    expireTime String
    The expiration time for instance, formatted in RFC3339 time string.
    id String
    The provider-assigned unique ID for this managed resource.
    ipSets List<InstanceIpSet>
    It is a nested type which documented below.
    memory Double
    The size of memory, measured in GB(Gigabyte).
    rdmaClusterId String
    The RDMA Cluster ID of instance. This is only available when machine type is O.
    status String
    Instance current status. Possible values are Initializing, Starting, Running, Stopping, Stopped, Install Fail, ResizeFail and Rebooting.
    autoRenew boolean
    Whether to renew an instance automatically or not.
    cpu number
    The number of cores of virtual CPU, measured in core.
    cpuPlatform string
    createTime string
    The time of creation for instance, formatted in RFC3339 time string.
    diskSets InstanceDiskSet[]
    It is a nested type which documented below.
    expireTime string
    The expiration time for instance, formatted in RFC3339 time string.
    id string
    The provider-assigned unique ID for this managed resource.
    ipSets InstanceIpSet[]
    It is a nested type which documented below.
    memory number
    The size of memory, measured in GB(Gigabyte).
    rdmaClusterId string
    The RDMA Cluster ID of instance. This is only available when machine type is O.
    status string
    Instance current status. Possible values are Initializing, Starting, Running, Stopping, Stopped, Install Fail, ResizeFail and Rebooting.
    auto_renew bool
    Whether to renew an instance automatically or not.
    cpu float
    The number of cores of virtual CPU, measured in core.
    cpu_platform str
    create_time str
    The time of creation for instance, formatted in RFC3339 time string.
    disk_sets Sequence[InstanceDiskSet]
    It is a nested type which documented below.
    expire_time str
    The expiration time for instance, formatted in RFC3339 time string.
    id str
    The provider-assigned unique ID for this managed resource.
    ip_sets Sequence[InstanceIpSet]
    It is a nested type which documented below.
    memory float
    The size of memory, measured in GB(Gigabyte).
    rdma_cluster_id str
    The RDMA Cluster ID of instance. This is only available when machine type is O.
    status str
    Instance current status. Possible values are Initializing, Starting, Running, Stopping, Stopped, Install Fail, ResizeFail and Rebooting.
    autoRenew Boolean
    Whether to renew an instance automatically or not.
    cpu Number
    The number of cores of virtual CPU, measured in core.
    cpuPlatform String
    createTime String
    The time of creation for instance, formatted in RFC3339 time string.
    diskSets List<Property Map>
    It is a nested type which documented below.
    expireTime String
    The expiration time for instance, formatted in RFC3339 time string.
    id String
    The provider-assigned unique ID for this managed resource.
    ipSets List<Property Map>
    It is a nested type which documented below.
    memory Number
    The size of memory, measured in GB(Gigabyte).
    rdmaClusterId String
    The RDMA Cluster ID of instance. This is only available when machine type is O.
    status String
    Instance current status. Possible values are Initializing, Starting, Running, Stopping, Stopped, Install Fail, ResizeFail and Rebooting.

    Look up Existing Instance Resource

    Get an existing Instance resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: InstanceState, opts?: CustomResourceOptions): Instance
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            allow_stopping_for_update: Optional[bool] = None,
            auto_renew: Optional[bool] = None,
            availability_zone: Optional[str] = None,
            boot_disk_size: Optional[float] = None,
            boot_disk_type: Optional[str] = None,
            charge_type: Optional[str] = None,
            cpu: Optional[float] = None,
            cpu_platform: Optional[str] = None,
            create_time: Optional[str] = None,
            data_disk_size: Optional[float] = None,
            data_disk_type: Optional[str] = None,
            data_disks: Optional[InstanceDataDisksArgs] = None,
            delete_disks_with_instance: Optional[bool] = None,
            delete_eips_with_instance: Optional[bool] = None,
            disk_sets: Optional[Sequence[InstanceDiskSetArgs]] = None,
            duration: Optional[float] = None,
            expire_time: Optional[str] = None,
            image_id: Optional[str] = None,
            instance_id: Optional[str] = None,
            instance_type: Optional[str] = None,
            ip_sets: Optional[Sequence[InstanceIpSetArgs]] = None,
            isolation_group: Optional[str] = None,
            memory: Optional[float] = None,
            min_cpu_platform: Optional[str] = None,
            name: Optional[str] = None,
            network_interface: Optional[InstanceNetworkInterfaceArgs] = None,
            private_ip: Optional[str] = None,
            rdma_cluster_id: Optional[str] = None,
            remark: Optional[str] = None,
            root_password: Optional[str] = None,
            security_group: Optional[str] = None,
            status: Optional[str] = None,
            subnet_id: Optional[str] = None,
            tag: Optional[str] = None,
            timeouts: Optional[InstanceTimeoutsArgs] = None,
            user_data: Optional[str] = None,
            vpc_id: Optional[str] = None) -> Instance
    func GetInstance(ctx *Context, name string, id IDInput, state *InstanceState, opts ...ResourceOption) (*Instance, error)
    public static Instance Get(string name, Input<string> id, InstanceState? state, CustomResourceOptions? opts = null)
    public static Instance get(String name, Output<String> id, InstanceState state, CustomResourceOptions options)
    resources:  _:    type: ucloud:Instance    get:      id: ${id}
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    AllowStoppingForUpdate bool
    AutoRenew bool
    Whether to renew an instance automatically or not.
    AvailabilityZone string
    Availability zone where instance is located. such as: cn-bj2-02. You may refer to list of availability zone
    BootDiskSize double

    The size of the boot disk, measured in GB (GigaByte). Range: 20-500. The value set of disk size must be larger or equal to 20(default: 20) for Linux and 40 (default: 40) for Windows. The responsive time is a bit longer if the value set is larger than default for local boot disk, and further settings may be required on host instance if the value set is larger than default for cloud boot disk. The disk volume adjustment must be a multiple of 10 GB. In addition, any reduction of boot disk size is not supported.

    Note If you want to update this value, you must set allow_stopping_for_updateto true. In addition, when it is changed, you need to go to the instance for configuration.

    BootDiskType string
    The type of boot disk. Possible values are: local_normal and local_ssd for local boot disk, cloud_ssd for cloud SSD boot disk,rssd_data_disk as RDMA-SSD cloud disk. (Default: local_normal). The local_ssd and cloud_ssd are not fully support by all regions as boot disk type, please proceed to UCloud console for more details.
    ChargeType string
    The charge type of instance, possible values are: year, month and dynamic as pay by hour (specific permission required). (Default: month).
    Cpu double
    The number of cores of virtual CPU, measured in core.
    CpuPlatform string
    CreateTime string
    The time of creation for instance, formatted in RFC3339 time string.
    DataDiskSize double

    The size of local data disk, measured in GB (GigaByte), 20-2000 for local sata disk and 20-1000 for local ssd disk (all the GPU type instances are included). The volume adjustment must be a multiple of 10 GB. In addition, any reduction of data disk size is not supported.

    Note If you want to update this value, you must set allow_stopping_for_updateto true. In addition, when it is changed, you need to go to the instance for configuration.

    DataDiskType string
    The type of local data disk. Possible values are: local_normal and local_ssd for local data disk. (Default: local_normal). The local_ssd is not fully support by all regions as data disk type, please proceed to UCloud console for more details. In addition, the data_disk_type must be same as boot_disk_type if specified.
    DataDisks InstanceDataDisks
    Additional cloud data disks to attach to the instance. data_disks configurations only apply on resource creation. The count of data_disks can only be one. See data_disks below for details on attributes. When set data_disks, the argument delete_disks_with_instance must bet set.
    DeleteDisksWithInstance bool
    DeleteEipsWithInstance bool
    DiskSets List<InstanceDiskSet>
    It is a nested type which documented below.
    Duration double
    The duration that you will buy the instance (Default: 1). The value is 0 when pay by month and the instance will be valid till the last day of that month. It is not required when dynamic (pay by hour).
    ExpireTime string
    The expiration time for instance, formatted in RFC3339 time string.
    ImageId string
    The ID for the image to use for the instance.
    InstanceId string
    The ID of disk.
    InstanceType string

    The type of instance, please visit the instance type table

    Note If you want to update this value, you must set allow_stopping_for_updateto true.


    IpSets List<InstanceIpSet>
    It is a nested type which documented below.
    IsolationGroup string
    The ID of the associated isolation group.
    Memory double
    The size of memory, measured in GB(Gigabyte).
    MinCpuPlatform string
    Specifies a minimum CPU platform for the the VM instance. (Default: Intel/Auto). You may refer to product documentation and API documentation.
    Name string
    NetworkInterface InstanceNetworkInterface
    PrivateIp string
    The private IP address assigned to the instance.
    RdmaClusterId string
    The RDMA Cluster ID of instance. This is only available when machine type is O.
    Remark string
    The remarks of instance. (Default: "").
    RootPassword string
    SecurityGroup string
    The ID of the associated security group.
    Status string
    Instance current status. Possible values are Initializing, Starting, Running, Stopping, Stopped, Install Fail, ResizeFail and Rebooting.
    SubnetId string
    The ID of subnet. If defined vpc_id, the subnet_id is Required. If not defined vpc_id and subnet_id, the instance will use the default subnet in the current region.
    Tag string
    A tag assigned to instance, which contains at most 63 characters and only support Chinese, English, numbers, '-', '_', and '.'. If it is not filled in or a empty string is filled in, then default tag will be assigned. (Default: Default).
    Timeouts InstanceTimeouts
    UserData string
    The user data to customize the startup behaviors when launching the instance. You may refer to user_data_document
    VpcId string
    The ID of VPC linked to the instance. If not defined vpc_id, the instance will use the default VPC in the current region.
    AllowStoppingForUpdate bool
    AutoRenew bool
    Whether to renew an instance automatically or not.
    AvailabilityZone string
    Availability zone where instance is located. such as: cn-bj2-02. You may refer to list of availability zone
    BootDiskSize float64

    The size of the boot disk, measured in GB (GigaByte). Range: 20-500. The value set of disk size must be larger or equal to 20(default: 20) for Linux and 40 (default: 40) for Windows. The responsive time is a bit longer if the value set is larger than default for local boot disk, and further settings may be required on host instance if the value set is larger than default for cloud boot disk. The disk volume adjustment must be a multiple of 10 GB. In addition, any reduction of boot disk size is not supported.

    Note If you want to update this value, you must set allow_stopping_for_updateto true. In addition, when it is changed, you need to go to the instance for configuration.

    BootDiskType string
    The type of boot disk. Possible values are: local_normal and local_ssd for local boot disk, cloud_ssd for cloud SSD boot disk,rssd_data_disk as RDMA-SSD cloud disk. (Default: local_normal). The local_ssd and cloud_ssd are not fully support by all regions as boot disk type, please proceed to UCloud console for more details.
    ChargeType string
    The charge type of instance, possible values are: year, month and dynamic as pay by hour (specific permission required). (Default: month).
    Cpu float64
    The number of cores of virtual CPU, measured in core.
    CpuPlatform string
    CreateTime string
    The time of creation for instance, formatted in RFC3339 time string.
    DataDiskSize float64

    The size of local data disk, measured in GB (GigaByte), 20-2000 for local sata disk and 20-1000 for local ssd disk (all the GPU type instances are included). The volume adjustment must be a multiple of 10 GB. In addition, any reduction of data disk size is not supported.

    Note If you want to update this value, you must set allow_stopping_for_updateto true. In addition, when it is changed, you need to go to the instance for configuration.

    DataDiskType string
    The type of local data disk. Possible values are: local_normal and local_ssd for local data disk. (Default: local_normal). The local_ssd is not fully support by all regions as data disk type, please proceed to UCloud console for more details. In addition, the data_disk_type must be same as boot_disk_type if specified.
    DataDisks InstanceDataDisksArgs
    Additional cloud data disks to attach to the instance. data_disks configurations only apply on resource creation. The count of data_disks can only be one. See data_disks below for details on attributes. When set data_disks, the argument delete_disks_with_instance must bet set.
    DeleteDisksWithInstance bool
    DeleteEipsWithInstance bool
    DiskSets []InstanceDiskSetArgs
    It is a nested type which documented below.
    Duration float64
    The duration that you will buy the instance (Default: 1). The value is 0 when pay by month and the instance will be valid till the last day of that month. It is not required when dynamic (pay by hour).
    ExpireTime string
    The expiration time for instance, formatted in RFC3339 time string.
    ImageId string
    The ID for the image to use for the instance.
    InstanceId string
    The ID of disk.
    InstanceType string

    The type of instance, please visit the instance type table

    Note If you want to update this value, you must set allow_stopping_for_updateto true.


    IpSets []InstanceIpSetArgs
    It is a nested type which documented below.
    IsolationGroup string
    The ID of the associated isolation group.
    Memory float64
    The size of memory, measured in GB(Gigabyte).
    MinCpuPlatform string
    Specifies a minimum CPU platform for the the VM instance. (Default: Intel/Auto). You may refer to product documentation and API documentation.
    Name string
    NetworkInterface InstanceNetworkInterfaceArgs
    PrivateIp string
    The private IP address assigned to the instance.
    RdmaClusterId string
    The RDMA Cluster ID of instance. This is only available when machine type is O.
    Remark string
    The remarks of instance. (Default: "").
    RootPassword string
    SecurityGroup string
    The ID of the associated security group.
    Status string
    Instance current status. Possible values are Initializing, Starting, Running, Stopping, Stopped, Install Fail, ResizeFail and Rebooting.
    SubnetId string
    The ID of subnet. If defined vpc_id, the subnet_id is Required. If not defined vpc_id and subnet_id, the instance will use the default subnet in the current region.
    Tag string
    A tag assigned to instance, which contains at most 63 characters and only support Chinese, English, numbers, '-', '_', and '.'. If it is not filled in or a empty string is filled in, then default tag will be assigned. (Default: Default).
    Timeouts InstanceTimeoutsArgs
    UserData string
    The user data to customize the startup behaviors when launching the instance. You may refer to user_data_document
    VpcId string
    The ID of VPC linked to the instance. If not defined vpc_id, the instance will use the default VPC in the current region.
    allowStoppingForUpdate Boolean
    autoRenew Boolean
    Whether to renew an instance automatically or not.
    availabilityZone String
    Availability zone where instance is located. such as: cn-bj2-02. You may refer to list of availability zone
    bootDiskSize Double

    The size of the boot disk, measured in GB (GigaByte). Range: 20-500. The value set of disk size must be larger or equal to 20(default: 20) for Linux and 40 (default: 40) for Windows. The responsive time is a bit longer if the value set is larger than default for local boot disk, and further settings may be required on host instance if the value set is larger than default for cloud boot disk. The disk volume adjustment must be a multiple of 10 GB. In addition, any reduction of boot disk size is not supported.

    Note If you want to update this value, you must set allow_stopping_for_updateto true. In addition, when it is changed, you need to go to the instance for configuration.

    bootDiskType String
    The type of boot disk. Possible values are: local_normal and local_ssd for local boot disk, cloud_ssd for cloud SSD boot disk,rssd_data_disk as RDMA-SSD cloud disk. (Default: local_normal). The local_ssd and cloud_ssd are not fully support by all regions as boot disk type, please proceed to UCloud console for more details.
    chargeType String
    The charge type of instance, possible values are: year, month and dynamic as pay by hour (specific permission required). (Default: month).
    cpu Double
    The number of cores of virtual CPU, measured in core.
    cpuPlatform String
    createTime String
    The time of creation for instance, formatted in RFC3339 time string.
    dataDiskSize Double

    The size of local data disk, measured in GB (GigaByte), 20-2000 for local sata disk and 20-1000 for local ssd disk (all the GPU type instances are included). The volume adjustment must be a multiple of 10 GB. In addition, any reduction of data disk size is not supported.

    Note If you want to update this value, you must set allow_stopping_for_updateto true. In addition, when it is changed, you need to go to the instance for configuration.

    dataDiskType String
    The type of local data disk. Possible values are: local_normal and local_ssd for local data disk. (Default: local_normal). The local_ssd is not fully support by all regions as data disk type, please proceed to UCloud console for more details. In addition, the data_disk_type must be same as boot_disk_type if specified.
    dataDisks InstanceDataDisks
    Additional cloud data disks to attach to the instance. data_disks configurations only apply on resource creation. The count of data_disks can only be one. See data_disks below for details on attributes. When set data_disks, the argument delete_disks_with_instance must bet set.
    deleteDisksWithInstance Boolean
    deleteEipsWithInstance Boolean
    diskSets List<InstanceDiskSet>
    It is a nested type which documented below.
    duration Double
    The duration that you will buy the instance (Default: 1). The value is 0 when pay by month and the instance will be valid till the last day of that month. It is not required when dynamic (pay by hour).
    expireTime String
    The expiration time for instance, formatted in RFC3339 time string.
    imageId String
    The ID for the image to use for the instance.
    instanceId String
    The ID of disk.
    instanceType String

    The type of instance, please visit the instance type table

    Note If you want to update this value, you must set allow_stopping_for_updateto true.


    ipSets List<InstanceIpSet>
    It is a nested type which documented below.
    isolationGroup String
    The ID of the associated isolation group.
    memory Double
    The size of memory, measured in GB(Gigabyte).
    minCpuPlatform String
    Specifies a minimum CPU platform for the the VM instance. (Default: Intel/Auto). You may refer to product documentation and API documentation.
    name String
    networkInterface InstanceNetworkInterface
    privateIp String
    The private IP address assigned to the instance.
    rdmaClusterId String
    The RDMA Cluster ID of instance. This is only available when machine type is O.
    remark String
    The remarks of instance. (Default: "").
    rootPassword String
    securityGroup String
    The ID of the associated security group.
    status String
    Instance current status. Possible values are Initializing, Starting, Running, Stopping, Stopped, Install Fail, ResizeFail and Rebooting.
    subnetId String
    The ID of subnet. If defined vpc_id, the subnet_id is Required. If not defined vpc_id and subnet_id, the instance will use the default subnet in the current region.
    tag String
    A tag assigned to instance, which contains at most 63 characters and only support Chinese, English, numbers, '-', '_', and '.'. If it is not filled in or a empty string is filled in, then default tag will be assigned. (Default: Default).
    timeouts InstanceTimeouts
    userData String
    The user data to customize the startup behaviors when launching the instance. You may refer to user_data_document
    vpcId String
    The ID of VPC linked to the instance. If not defined vpc_id, the instance will use the default VPC in the current region.
    allowStoppingForUpdate boolean
    autoRenew boolean
    Whether to renew an instance automatically or not.
    availabilityZone string
    Availability zone where instance is located. such as: cn-bj2-02. You may refer to list of availability zone
    bootDiskSize number

    The size of the boot disk, measured in GB (GigaByte). Range: 20-500. The value set of disk size must be larger or equal to 20(default: 20) for Linux and 40 (default: 40) for Windows. The responsive time is a bit longer if the value set is larger than default for local boot disk, and further settings may be required on host instance if the value set is larger than default for cloud boot disk. The disk volume adjustment must be a multiple of 10 GB. In addition, any reduction of boot disk size is not supported.

    Note If you want to update this value, you must set allow_stopping_for_updateto true. In addition, when it is changed, you need to go to the instance for configuration.

    bootDiskType string
    The type of boot disk. Possible values are: local_normal and local_ssd for local boot disk, cloud_ssd for cloud SSD boot disk,rssd_data_disk as RDMA-SSD cloud disk. (Default: local_normal). The local_ssd and cloud_ssd are not fully support by all regions as boot disk type, please proceed to UCloud console for more details.
    chargeType string
    The charge type of instance, possible values are: year, month and dynamic as pay by hour (specific permission required). (Default: month).
    cpu number
    The number of cores of virtual CPU, measured in core.
    cpuPlatform string
    createTime string
    The time of creation for instance, formatted in RFC3339 time string.
    dataDiskSize number

    The size of local data disk, measured in GB (GigaByte), 20-2000 for local sata disk and 20-1000 for local ssd disk (all the GPU type instances are included). The volume adjustment must be a multiple of 10 GB. In addition, any reduction of data disk size is not supported.

    Note If you want to update this value, you must set allow_stopping_for_updateto true. In addition, when it is changed, you need to go to the instance for configuration.

    dataDiskType string
    The type of local data disk. Possible values are: local_normal and local_ssd for local data disk. (Default: local_normal). The local_ssd is not fully support by all regions as data disk type, please proceed to UCloud console for more details. In addition, the data_disk_type must be same as boot_disk_type if specified.
    dataDisks InstanceDataDisks
    Additional cloud data disks to attach to the instance. data_disks configurations only apply on resource creation. The count of data_disks can only be one. See data_disks below for details on attributes. When set data_disks, the argument delete_disks_with_instance must bet set.
    deleteDisksWithInstance boolean
    deleteEipsWithInstance boolean
    diskSets InstanceDiskSet[]
    It is a nested type which documented below.
    duration number
    The duration that you will buy the instance (Default: 1). The value is 0 when pay by month and the instance will be valid till the last day of that month. It is not required when dynamic (pay by hour).
    expireTime string
    The expiration time for instance, formatted in RFC3339 time string.
    imageId string
    The ID for the image to use for the instance.
    instanceId string
    The ID of disk.
    instanceType string

    The type of instance, please visit the instance type table

    Note If you want to update this value, you must set allow_stopping_for_updateto true.


    ipSets InstanceIpSet[]
    It is a nested type which documented below.
    isolationGroup string
    The ID of the associated isolation group.
    memory number
    The size of memory, measured in GB(Gigabyte).
    minCpuPlatform string
    Specifies a minimum CPU platform for the the VM instance. (Default: Intel/Auto). You may refer to product documentation and API documentation.
    name string
    networkInterface InstanceNetworkInterface
    privateIp string
    The private IP address assigned to the instance.
    rdmaClusterId string
    The RDMA Cluster ID of instance. This is only available when machine type is O.
    remark string
    The remarks of instance. (Default: "").
    rootPassword string
    securityGroup string
    The ID of the associated security group.
    status string
    Instance current status. Possible values are Initializing, Starting, Running, Stopping, Stopped, Install Fail, ResizeFail and Rebooting.
    subnetId string
    The ID of subnet. If defined vpc_id, the subnet_id is Required. If not defined vpc_id and subnet_id, the instance will use the default subnet in the current region.
    tag string
    A tag assigned to instance, which contains at most 63 characters and only support Chinese, English, numbers, '-', '_', and '.'. If it is not filled in or a empty string is filled in, then default tag will be assigned. (Default: Default).
    timeouts InstanceTimeouts
    userData string
    The user data to customize the startup behaviors when launching the instance. You may refer to user_data_document
    vpcId string
    The ID of VPC linked to the instance. If not defined vpc_id, the instance will use the default VPC in the current region.
    allow_stopping_for_update bool
    auto_renew bool
    Whether to renew an instance automatically or not.
    availability_zone str
    Availability zone where instance is located. such as: cn-bj2-02. You may refer to list of availability zone
    boot_disk_size float

    The size of the boot disk, measured in GB (GigaByte). Range: 20-500. The value set of disk size must be larger or equal to 20(default: 20) for Linux and 40 (default: 40) for Windows. The responsive time is a bit longer if the value set is larger than default for local boot disk, and further settings may be required on host instance if the value set is larger than default for cloud boot disk. The disk volume adjustment must be a multiple of 10 GB. In addition, any reduction of boot disk size is not supported.

    Note If you want to update this value, you must set allow_stopping_for_updateto true. In addition, when it is changed, you need to go to the instance for configuration.

    boot_disk_type str
    The type of boot disk. Possible values are: local_normal and local_ssd for local boot disk, cloud_ssd for cloud SSD boot disk,rssd_data_disk as RDMA-SSD cloud disk. (Default: local_normal). The local_ssd and cloud_ssd are not fully support by all regions as boot disk type, please proceed to UCloud console for more details.
    charge_type str
    The charge type of instance, possible values are: year, month and dynamic as pay by hour (specific permission required). (Default: month).
    cpu float
    The number of cores of virtual CPU, measured in core.
    cpu_platform str
    create_time str
    The time of creation for instance, formatted in RFC3339 time string.
    data_disk_size float

    The size of local data disk, measured in GB (GigaByte), 20-2000 for local sata disk and 20-1000 for local ssd disk (all the GPU type instances are included). The volume adjustment must be a multiple of 10 GB. In addition, any reduction of data disk size is not supported.

    Note If you want to update this value, you must set allow_stopping_for_updateto true. In addition, when it is changed, you need to go to the instance for configuration.

    data_disk_type str
    The type of local data disk. Possible values are: local_normal and local_ssd for local data disk. (Default: local_normal). The local_ssd is not fully support by all regions as data disk type, please proceed to UCloud console for more details. In addition, the data_disk_type must be same as boot_disk_type if specified.
    data_disks InstanceDataDisksArgs
    Additional cloud data disks to attach to the instance. data_disks configurations only apply on resource creation. The count of data_disks can only be one. See data_disks below for details on attributes. When set data_disks, the argument delete_disks_with_instance must bet set.
    delete_disks_with_instance bool
    delete_eips_with_instance bool
    disk_sets Sequence[InstanceDiskSetArgs]
    It is a nested type which documented below.
    duration float
    The duration that you will buy the instance (Default: 1). The value is 0 when pay by month and the instance will be valid till the last day of that month. It is not required when dynamic (pay by hour).
    expire_time str
    The expiration time for instance, formatted in RFC3339 time string.
    image_id str
    The ID for the image to use for the instance.
    instance_id str
    The ID of disk.
    instance_type str

    The type of instance, please visit the instance type table

    Note If you want to update this value, you must set allow_stopping_for_updateto true.


    ip_sets Sequence[InstanceIpSetArgs]
    It is a nested type which documented below.
    isolation_group str
    The ID of the associated isolation group.
    memory float
    The size of memory, measured in GB(Gigabyte).
    min_cpu_platform str
    Specifies a minimum CPU platform for the the VM instance. (Default: Intel/Auto). You may refer to product documentation and API documentation.
    name str
    network_interface InstanceNetworkInterfaceArgs
    private_ip str
    The private IP address assigned to the instance.
    rdma_cluster_id str
    The RDMA Cluster ID of instance. This is only available when machine type is O.
    remark str
    The remarks of instance. (Default: "").
    root_password str
    security_group str
    The ID of the associated security group.
    status str
    Instance current status. Possible values are Initializing, Starting, Running, Stopping, Stopped, Install Fail, ResizeFail and Rebooting.
    subnet_id str
    The ID of subnet. If defined vpc_id, the subnet_id is Required. If not defined vpc_id and subnet_id, the instance will use the default subnet in the current region.
    tag str
    A tag assigned to instance, which contains at most 63 characters and only support Chinese, English, numbers, '-', '_', and '.'. If it is not filled in or a empty string is filled in, then default tag will be assigned. (Default: Default).
    timeouts InstanceTimeoutsArgs
    user_data str
    The user data to customize the startup behaviors when launching the instance. You may refer to user_data_document
    vpc_id str
    The ID of VPC linked to the instance. If not defined vpc_id, the instance will use the default VPC in the current region.
    allowStoppingForUpdate Boolean
    autoRenew Boolean
    Whether to renew an instance automatically or not.
    availabilityZone String
    Availability zone where instance is located. such as: cn-bj2-02. You may refer to list of availability zone
    bootDiskSize Number

    The size of the boot disk, measured in GB (GigaByte). Range: 20-500. The value set of disk size must be larger or equal to 20(default: 20) for Linux and 40 (default: 40) for Windows. The responsive time is a bit longer if the value set is larger than default for local boot disk, and further settings may be required on host instance if the value set is larger than default for cloud boot disk. The disk volume adjustment must be a multiple of 10 GB. In addition, any reduction of boot disk size is not supported.

    Note If you want to update this value, you must set allow_stopping_for_updateto true. In addition, when it is changed, you need to go to the instance for configuration.

    bootDiskType String
    The type of boot disk. Possible values are: local_normal and local_ssd for local boot disk, cloud_ssd for cloud SSD boot disk,rssd_data_disk as RDMA-SSD cloud disk. (Default: local_normal). The local_ssd and cloud_ssd are not fully support by all regions as boot disk type, please proceed to UCloud console for more details.
    chargeType String
    The charge type of instance, possible values are: year, month and dynamic as pay by hour (specific permission required). (Default: month).
    cpu Number
    The number of cores of virtual CPU, measured in core.
    cpuPlatform String
    createTime String
    The time of creation for instance, formatted in RFC3339 time string.
    dataDiskSize Number

    The size of local data disk, measured in GB (GigaByte), 20-2000 for local sata disk and 20-1000 for local ssd disk (all the GPU type instances are included). The volume adjustment must be a multiple of 10 GB. In addition, any reduction of data disk size is not supported.

    Note If you want to update this value, you must set allow_stopping_for_updateto true. In addition, when it is changed, you need to go to the instance for configuration.

    dataDiskType String
    The type of local data disk. Possible values are: local_normal and local_ssd for local data disk. (Default: local_normal). The local_ssd is not fully support by all regions as data disk type, please proceed to UCloud console for more details. In addition, the data_disk_type must be same as boot_disk_type if specified.
    dataDisks Property Map
    Additional cloud data disks to attach to the instance. data_disks configurations only apply on resource creation. The count of data_disks can only be one. See data_disks below for details on attributes. When set data_disks, the argument delete_disks_with_instance must bet set.
    deleteDisksWithInstance Boolean
    deleteEipsWithInstance Boolean
    diskSets List<Property Map>
    It is a nested type which documented below.
    duration Number
    The duration that you will buy the instance (Default: 1). The value is 0 when pay by month and the instance will be valid till the last day of that month. It is not required when dynamic (pay by hour).
    expireTime String
    The expiration time for instance, formatted in RFC3339 time string.
    imageId String
    The ID for the image to use for the instance.
    instanceId String
    The ID of disk.
    instanceType String

    The type of instance, please visit the instance type table

    Note If you want to update this value, you must set allow_stopping_for_updateto true.


    ipSets List<Property Map>
    It is a nested type which documented below.
    isolationGroup String
    The ID of the associated isolation group.
    memory Number
    The size of memory, measured in GB(Gigabyte).
    minCpuPlatform String
    Specifies a minimum CPU platform for the the VM instance. (Default: Intel/Auto). You may refer to product documentation and API documentation.
    name String
    networkInterface Property Map
    privateIp String
    The private IP address assigned to the instance.
    rdmaClusterId String
    The RDMA Cluster ID of instance. This is only available when machine type is O.
    remark String
    The remarks of instance. (Default: "").
    rootPassword String
    securityGroup String
    The ID of the associated security group.
    status String
    Instance current status. Possible values are Initializing, Starting, Running, Stopping, Stopped, Install Fail, ResizeFail and Rebooting.
    subnetId String
    The ID of subnet. If defined vpc_id, the subnet_id is Required. If not defined vpc_id and subnet_id, the instance will use the default subnet in the current region.
    tag String
    A tag assigned to instance, which contains at most 63 characters and only support Chinese, English, numbers, '-', '_', and '.'. If it is not filled in or a empty string is filled in, then default tag will be assigned. (Default: Default).
    timeouts Property Map
    userData String
    The user data to customize the startup behaviors when launching the instance. You may refer to user_data_document
    vpcId String
    The ID of VPC linked to the instance. If not defined vpc_id, the instance will use the default VPC in the current region.

    Supporting Types

    InstanceDataDisks, InstanceDataDisksArgs

    Size double
    The size of the cloud data disk, range 20-8000, measured in GB (GigaByte).
    Type string
    Size float64
    The size of the cloud data disk, range 20-8000, measured in GB (GigaByte).
    Type string
    size Double
    The size of the cloud data disk, range 20-8000, measured in GB (GigaByte).
    type String
    size number
    The size of the cloud data disk, range 20-8000, measured in GB (GigaByte).
    type string
    size float
    The size of the cloud data disk, range 20-8000, measured in GB (GigaByte).
    type str
    size Number
    The size of the cloud data disk, range 20-8000, measured in GB (GigaByte).
    type String

    InstanceDiskSet, InstanceDiskSetArgs

    Id string
    The ID of disk.
    IsBoot bool
    Specifies whether boot disk or not.
    Size double
    The size of disk, measured in GB (Gigabyte).
    Type string
    The type of disk.
    Id string
    The ID of disk.
    IsBoot bool
    Specifies whether boot disk or not.
    Size float64
    The size of disk, measured in GB (Gigabyte).
    Type string
    The type of disk.
    id String
    The ID of disk.
    isBoot Boolean
    Specifies whether boot disk or not.
    size Double
    The size of disk, measured in GB (Gigabyte).
    type String
    The type of disk.
    id string
    The ID of disk.
    isBoot boolean
    Specifies whether boot disk or not.
    size number
    The size of disk, measured in GB (Gigabyte).
    type string
    The type of disk.
    id str
    The ID of disk.
    is_boot bool
    Specifies whether boot disk or not.
    size float
    The size of disk, measured in GB (Gigabyte).
    type str
    The type of disk.
    id String
    The ID of disk.
    isBoot Boolean
    Specifies whether boot disk or not.
    size Number
    The size of disk, measured in GB (Gigabyte).
    type String
    The type of disk.

    InstanceIpSet, InstanceIpSetArgs

    InternetType string
    Type of Elastic IP routes. Possible values are: International as international BGP IP, BGP as china BGP IP and Private as private IP.
    Ip string
    Elastic IP address.
    InternetType string
    Type of Elastic IP routes. Possible values are: International as international BGP IP, BGP as china BGP IP and Private as private IP.
    Ip string
    Elastic IP address.
    internetType String
    Type of Elastic IP routes. Possible values are: International as international BGP IP, BGP as china BGP IP and Private as private IP.
    ip String
    Elastic IP address.
    internetType string
    Type of Elastic IP routes. Possible values are: International as international BGP IP, BGP as china BGP IP and Private as private IP.
    ip string
    Elastic IP address.
    internet_type str
    Type of Elastic IP routes. Possible values are: International as international BGP IP, BGP as china BGP IP and Private as private IP.
    ip str
    Elastic IP address.
    internetType String
    Type of Elastic IP routes. Possible values are: International as international BGP IP, BGP as china BGP IP and Private as private IP.
    ip String
    Elastic IP address.

    InstanceNetworkInterface, InstanceNetworkInterfaceArgs

    EipBandwidth double
    Maximum bandwidth to the elastic public network, measured in Mbps (Mega bit per second). The ranges for bandwidth are: 1-200 for pay by traffic, 1-800 for pay by bandwidth.
    EipChargeMode string
    EipInternetType string
    Type of Elastic IP routes. Possible values are: international as international BGP IP and bgp as china mainland BGP IP.
    EipBandwidth float64
    Maximum bandwidth to the elastic public network, measured in Mbps (Mega bit per second). The ranges for bandwidth are: 1-200 for pay by traffic, 1-800 for pay by bandwidth.
    EipChargeMode string
    EipInternetType string
    Type of Elastic IP routes. Possible values are: international as international BGP IP and bgp as china mainland BGP IP.
    eipBandwidth Double
    Maximum bandwidth to the elastic public network, measured in Mbps (Mega bit per second). The ranges for bandwidth are: 1-200 for pay by traffic, 1-800 for pay by bandwidth.
    eipChargeMode String
    eipInternetType String
    Type of Elastic IP routes. Possible values are: international as international BGP IP and bgp as china mainland BGP IP.
    eipBandwidth number
    Maximum bandwidth to the elastic public network, measured in Mbps (Mega bit per second). The ranges for bandwidth are: 1-200 for pay by traffic, 1-800 for pay by bandwidth.
    eipChargeMode string
    eipInternetType string
    Type of Elastic IP routes. Possible values are: international as international BGP IP and bgp as china mainland BGP IP.
    eip_bandwidth float
    Maximum bandwidth to the elastic public network, measured in Mbps (Mega bit per second). The ranges for bandwidth are: 1-200 for pay by traffic, 1-800 for pay by bandwidth.
    eip_charge_mode str
    eip_internet_type str
    Type of Elastic IP routes. Possible values are: international as international BGP IP and bgp as china mainland BGP IP.
    eipBandwidth Number
    Maximum bandwidth to the elastic public network, measured in Mbps (Mega bit per second). The ranges for bandwidth are: 1-200 for pay by traffic, 1-800 for pay by bandwidth.
    eipChargeMode String
    eipInternetType String
    Type of Elastic IP routes. Possible values are: international as international BGP IP and bgp as china mainland BGP IP.

    InstanceTimeouts, InstanceTimeoutsArgs

    Create string
    Used when launching the instance (until it reaches the initial Running state)
    Delete string
    Used when terminating the instance
    Update string
    Used when updating the arguments of the instance if necessary - e.g. when changing instance_type
    Create string
    Used when launching the instance (until it reaches the initial Running state)
    Delete string
    Used when terminating the instance
    Update string
    Used when updating the arguments of the instance if necessary - e.g. when changing instance_type
    create String
    Used when launching the instance (until it reaches the initial Running state)
    delete String
    Used when terminating the instance
    update String
    Used when updating the arguments of the instance if necessary - e.g. when changing instance_type
    create string
    Used when launching the instance (until it reaches the initial Running state)
    delete string
    Used when terminating the instance
    update string
    Used when updating the arguments of the instance if necessary - e.g. when changing instance_type
    create str
    Used when launching the instance (until it reaches the initial Running state)
    delete str
    Used when terminating the instance
    update str
    Used when updating the arguments of the instance if necessary - e.g. when changing instance_type
    create String
    Used when launching the instance (until it reaches the initial Running state)
    delete String
    Used when terminating the instance
    update String
    Used when updating the arguments of the instance if necessary - e.g. when changing instance_type

    Import

    Instance can be imported using the id, e.g.

    $ pulumi import ucloud:index/instance:Instance example uhost-abcdefg
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    ucloud ucloud/terraform-provider-ucloud
    License
    Notes
    This Pulumi package is based on the ucloud Terraform Provider.
    ucloud logo
    ucloud 1.39.1 published on Monday, Apr 14, 2025 by ucloud