Alibaba Cloud

Pulumi Official
Package maintained by Pulumi
v3.27.0 published on Monday, Aug 8, 2022 by Pulumi

EcsLaunchTemplate

Provides a ECS Launch Template resource.

For information about ECS Launch Template and how to use it, see What is Launch Template.

NOTE: Available in v1.120.0+.

Example Usage

using Pulumi;
using AliCloud = Pulumi.AliCloud;

class MyStack : Stack
{
    public MyStack()
    {
        var @default = new AliCloud.Ecs.EcsLaunchTemplate("default", new AliCloud.Ecs.EcsLaunchTemplateArgs
        {
            DataDisks = 
            {
                new AliCloud.Ecs.Inputs.EcsLaunchTemplateDataDiskArgs
                {
                    Category = "cloud",
                    DeleteWithInstance = true,
                    Description = "test1",
                    Encrypted = false,
                    Name = "disk1",
                    PerformanceLevel = "PL0",
                    Size = 20,
                },
                new AliCloud.Ecs.Inputs.EcsLaunchTemplateDataDiskArgs
                {
                    Category = "cloud",
                    DeleteWithInstance = true,
                    Description = "test2",
                    Encrypted = false,
                    Name = "disk2",
                    PerformanceLevel = "PL0",
                    Size = 20,
                },
            },
            Description = "Test For Terraform",
            HostName = "host_name",
            ImageId = "m-bp1i3ucxxxxx",
            InstanceChargeType = "PrePaid",
            InstanceName = "instance_name",
            InstanceType = "instance_type",
            InternetChargeType = "PayByBandwidth",
            InternetMaxBandwidthIn = 5,
            InternetMaxBandwidthOut = 0,
            IoOptimized = "optimized",
            KeyPairName = "key_pair_name",
            NetworkInterfaces = new AliCloud.Ecs.Inputs.EcsLaunchTemplateNetworkInterfacesArgs
            {
                Description = "hello1",
                Name = "eth0",
                PrimaryIp = "10.0.0.2",
                SecurityGroupId = "sg-asdfnbgxxxxxxx",
                VswitchId = "vw-zkdfjaxxxxxx",
            },
            NetworkType = "vpc",
            RamRoleName = "ram_role_name",
            ResourceGroupId = "rg-zkdfjaxxxxxx",
            SecurityEnhancementStrategy = "Active",
            SecurityGroupIds = 
            {
                "sg-zkdfjaxxxxxx",
            },
            SpotPriceLimit = 5,
            SpotStrategy = "SpotWithPriceLimit",
            SystemDisk = new AliCloud.Ecs.Inputs.EcsLaunchTemplateSystemDiskArgs
            {
                Category = "cloud_ssd",
                DeleteWithInstance = false,
                Description = "Test For Terraform",
                Name = "tf_test_name",
                Size = 40,
            },
            TemplateTags = 
            {
                { "Create", "Terraform" },
                { "For", "Test" },
            },
            UserData = "xxxxxxx",
            VpcId = "vpc-asdfnbgxxxxxxx",
            VswitchId = "vw-zwxscaxxxxxx",
            ZoneId = "cn-hangzhou-i",
        });
    }

}
package main

import (
	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/ecs"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := ecs.NewEcsLaunchTemplate(ctx, "default", &ecs.EcsLaunchTemplateArgs{
			DataDisks: ecs.EcsLaunchTemplateDataDiskArray{
				&ecs.EcsLaunchTemplateDataDiskArgs{
					Category:           pulumi.String("cloud"),
					DeleteWithInstance: pulumi.Bool(true),
					Description:        pulumi.String("test1"),
					Encrypted:          pulumi.Bool(false),
					Name:               pulumi.String("disk1"),
					PerformanceLevel:   pulumi.String("PL0"),
					Size:               pulumi.Int(20),
				},
				&ecs.EcsLaunchTemplateDataDiskArgs{
					Category:           pulumi.String("cloud"),
					DeleteWithInstance: pulumi.Bool(true),
					Description:        pulumi.String("test2"),
					Encrypted:          pulumi.Bool(false),
					Name:               pulumi.String("disk2"),
					PerformanceLevel:   pulumi.String("PL0"),
					Size:               pulumi.Int(20),
				},
			},
			Description:             pulumi.String("Test For Terraform"),
			HostName:                pulumi.String("host_name"),
			ImageId:                 pulumi.String("m-bp1i3ucxxxxx"),
			InstanceChargeType:      pulumi.String("PrePaid"),
			InstanceName:            pulumi.String("instance_name"),
			InstanceType:            pulumi.String("instance_type"),
			InternetChargeType:      pulumi.String("PayByBandwidth"),
			InternetMaxBandwidthIn:  pulumi.Int(5),
			InternetMaxBandwidthOut: pulumi.Int(0),
			IoOptimized:             pulumi.String("optimized"),
			KeyPairName:             pulumi.String("key_pair_name"),
			NetworkInterfaces: &ecs.EcsLaunchTemplateNetworkInterfacesArgs{
				Description:     pulumi.String("hello1"),
				Name:            pulumi.String("eth0"),
				PrimaryIp:       pulumi.String("10.0.0.2"),
				SecurityGroupId: pulumi.String("sg-asdfnbgxxxxxxx"),
				VswitchId:       pulumi.String("vw-zkdfjaxxxxxx"),
			},
			NetworkType:                 pulumi.String("vpc"),
			RamRoleName:                 pulumi.String("ram_role_name"),
			ResourceGroupId:             pulumi.String("rg-zkdfjaxxxxxx"),
			SecurityEnhancementStrategy: pulumi.String("Active"),
			SecurityGroupIds: pulumi.StringArray{
				pulumi.String("sg-zkdfjaxxxxxx"),
			},
			SpotPriceLimit: pulumi.Float64(5),
			SpotStrategy:   pulumi.String("SpotWithPriceLimit"),
			SystemDisk: &ecs.EcsLaunchTemplateSystemDiskArgs{
				Category:           pulumi.String("cloud_ssd"),
				DeleteWithInstance: pulumi.Bool(false),
				Description:        pulumi.String("Test For Terraform"),
				Name:               pulumi.String("tf_test_name"),
				Size:               pulumi.Int(40),
			},
			TemplateTags: pulumi.AnyMap{
				"Create": pulumi.Any("Terraform"),
				"For":    pulumi.Any("Test"),
			},
			UserData:  pulumi.String("xxxxxxx"),
			VpcId:     pulumi.String("vpc-asdfnbgxxxxxxx"),
			VswitchId: pulumi.String("vw-zwxscaxxxxxx"),
			ZoneId:    pulumi.String("cn-hangzhou-i"),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.ecs.EcsLaunchTemplate;
import com.pulumi.alicloud.ecs.EcsLaunchTemplateArgs;
import com.pulumi.alicloud.ecs.inputs.EcsLaunchTemplateDataDiskArgs;
import com.pulumi.alicloud.ecs.inputs.EcsLaunchTemplateNetworkInterfacesArgs;
import com.pulumi.alicloud.ecs.inputs.EcsLaunchTemplateSystemDiskArgs;
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) {
        var default_ = new EcsLaunchTemplate("default", EcsLaunchTemplateArgs.builder()        
            .dataDisks(            
                EcsLaunchTemplateDataDiskArgs.builder()
                    .category("cloud")
                    .deleteWithInstance("true")
                    .description("test1")
                    .encrypted("false")
                    .name("disk1")
                    .performanceLevel("PL0")
                    .size("20")
                    .build(),
                EcsLaunchTemplateDataDiskArgs.builder()
                    .category("cloud")
                    .deleteWithInstance("true")
                    .description("test2")
                    .encrypted("false")
                    .name("disk2")
                    .performanceLevel("PL0")
                    .size("20")
                    .build())
            .description("Test For Terraform")
            .hostName("host_name")
            .imageId("m-bp1i3ucxxxxx")
            .instanceChargeType("PrePaid")
            .instanceName("instance_name")
            .instanceType("instance_type")
            .internetChargeType("PayByBandwidth")
            .internetMaxBandwidthIn("5")
            .internetMaxBandwidthOut("0")
            .ioOptimized("optimized")
            .keyPairName("key_pair_name")
            .networkInterfaces(EcsLaunchTemplateNetworkInterfacesArgs.builder()
                .description("hello1")
                .name("eth0")
                .primaryIp("10.0.0.2")
                .securityGroupId("sg-asdfnbgxxxxxxx")
                .vswitchId("vw-zkdfjaxxxxxx")
                .build())
            .networkType("vpc")
            .ramRoleName("ram_role_name")
            .resourceGroupId("rg-zkdfjaxxxxxx")
            .securityEnhancementStrategy("Active")
            .securityGroupIds("sg-zkdfjaxxxxxx")
            .spotPriceLimit("5")
            .spotStrategy("SpotWithPriceLimit")
            .systemDisk(EcsLaunchTemplateSystemDiskArgs.builder()
                .category("cloud_ssd")
                .deleteWithInstance("false")
                .description("Test For Terraform")
                .name("tf_test_name")
                .size("40")
                .build())
            .templateTags(Map.ofEntries(
                Map.entry("Create", "Terraform"),
                Map.entry("For", "Test")
            ))
            .userData("xxxxxxx")
            .vpcId("vpc-asdfnbgxxxxxxx")
            .vswitchId("vw-zwxscaxxxxxx")
            .zoneId("cn-hangzhou-i")
            .build());

    }
}
import pulumi
import pulumi_alicloud as alicloud

default = alicloud.ecs.EcsLaunchTemplate("default",
    data_disks=[
        alicloud.ecs.EcsLaunchTemplateDataDiskArgs(
            category="cloud",
            delete_with_instance=True,
            description="test1",
            encrypted=False,
            name="disk1",
            performance_level="PL0",
            size=20,
        ),
        alicloud.ecs.EcsLaunchTemplateDataDiskArgs(
            category="cloud",
            delete_with_instance=True,
            description="test2",
            encrypted=False,
            name="disk2",
            performance_level="PL0",
            size=20,
        ),
    ],
    description="Test For Terraform",
    host_name="host_name",
    image_id="m-bp1i3ucxxxxx",
    instance_charge_type="PrePaid",
    instance_name="instance_name",
    instance_type="instance_type",
    internet_charge_type="PayByBandwidth",
    internet_max_bandwidth_in=5,
    internet_max_bandwidth_out=0,
    io_optimized="optimized",
    key_pair_name="key_pair_name",
    network_interfaces=alicloud.ecs.EcsLaunchTemplateNetworkInterfacesArgs(
        description="hello1",
        name="eth0",
        primary_ip="10.0.0.2",
        security_group_id="sg-asdfnbgxxxxxxx",
        vswitch_id="vw-zkdfjaxxxxxx",
    ),
    network_type="vpc",
    ram_role_name="ram_role_name",
    resource_group_id="rg-zkdfjaxxxxxx",
    security_enhancement_strategy="Active",
    security_group_ids=["sg-zkdfjaxxxxxx"],
    spot_price_limit=5,
    spot_strategy="SpotWithPriceLimit",
    system_disk=alicloud.ecs.EcsLaunchTemplateSystemDiskArgs(
        category="cloud_ssd",
        delete_with_instance=False,
        description="Test For Terraform",
        name="tf_test_name",
        size=40,
    ),
    template_tags={
        "Create": "Terraform",
        "For": "Test",
    },
    user_data="xxxxxxx",
    vpc_id="vpc-asdfnbgxxxxxxx",
    vswitch_id="vw-zwxscaxxxxxx",
    zone_id="cn-hangzhou-i")
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";

const defaultEcsLaunchTemplate = new alicloud.ecs.EcsLaunchTemplate("default", {
    dataDisks: [
        {
            category: "cloud",
            deleteWithInstance: true,
            description: "test1",
            encrypted: false,
            name: "disk1",
            performanceLevel: "PL0",
            size: 20,
        },
        {
            category: "cloud",
            deleteWithInstance: true,
            description: "test2",
            encrypted: false,
            name: "disk2",
            performanceLevel: "PL0",
            size: 20,
        },
    ],
    description: "Test For Terraform",
    hostName: "host_name",
    imageId: "m-bp1i3ucxxxxx",
    instanceChargeType: "PrePaid",
    instanceName: "instance_name",
    instanceType: "instance_type",
    internetChargeType: "PayByBandwidth",
    internetMaxBandwidthIn: 5,
    internetMaxBandwidthOut: 0,
    ioOptimized: "optimized",
    keyPairName: "key_pair_name",
    networkInterfaces: {
        description: "hello1",
        name: "eth0",
        primaryIp: "10.0.0.2",
        securityGroupId: "sg-asdfnbgxxxxxxx",
        vswitchId: "vw-zkdfjaxxxxxx",
    },
    networkType: "vpc",
    ramRoleName: "ram_role_name",
    resourceGroupId: "rg-zkdfjaxxxxxx",
    securityEnhancementStrategy: "Active",
    securityGroupIds: ["sg-zkdfjaxxxxxx"],
    spotPriceLimit: 5,
    spotStrategy: "SpotWithPriceLimit",
    systemDisk: {
        category: "cloud_ssd",
        deleteWithInstance: false,
        description: "Test For Terraform",
        name: "tf_test_name",
        size: 40,
    },
    templateTags: {
        Create: "Terraform",
        For: "Test",
    },
    userData: "xxxxxxx",
    vpcId: "vpc-asdfnbgxxxxxxx",
    vswitchId: "vw-zwxscaxxxxxx",
    zoneId: "cn-hangzhou-i",
});
resources:
  default:
    type: alicloud:ecs:EcsLaunchTemplate
    properties:
      dataDisks:
        - category: cloud
          deleteWithInstance: true
          description: test1
          encrypted: false
          name: disk1
          performanceLevel: PL0
          size: 20
        - category: cloud
          deleteWithInstance: true
          description: test2
          encrypted: false
          name: disk2
          performanceLevel: PL0
          size: 20
      description: Test For Terraform
      hostName: host_name
      imageId: m-bp1i3ucxxxxx
      instanceChargeType: PrePaid
      instanceName: instance_name
      instanceType: instance_type
      internetChargeType: PayByBandwidth
      internetMaxBandwidthIn: 5
      internetMaxBandwidthOut: 0
      ioOptimized: optimized
      keyPairName: key_pair_name
      networkInterfaces:
        description: hello1
        name: eth0
        primaryIp: 10.0.0.2
        securityGroupId: sg-asdfnbgxxxxxxx
        vswitchId: vw-zkdfjaxxxxxx
      networkType: vpc
      ramRoleName: ram_role_name
      resourceGroupId: rg-zkdfjaxxxxxx
      securityEnhancementStrategy: Active
      securityGroupIds:
        - sg-zkdfjaxxxxxx
      spotPriceLimit: 5
      spotStrategy: SpotWithPriceLimit
      systemDisk:
        category: cloud_ssd
        deleteWithInstance: false
        description: Test For Terraform
        name: tf_test_name
        size: 40
      templateTags:
        Create: Terraform
        For: Test
      userData: xxxxxxx
      vpcId: vpc-asdfnbgxxxxxxx
      vswitchId: vw-zwxscaxxxxxx
      zoneId: cn-hangzhou-i

Create a EcsLaunchTemplate Resource

new EcsLaunchTemplate(name: string, args?: EcsLaunchTemplateArgs, opts?: CustomResourceOptions);
@overload
def EcsLaunchTemplate(resource_name: str,
                      opts: Optional[ResourceOptions] = None,
                      auto_release_time: Optional[str] = None,
                      data_disks: Optional[Sequence[EcsLaunchTemplateDataDiskArgs]] = None,
                      deployment_set_id: Optional[str] = None,
                      description: Optional[str] = None,
                      enable_vm_os_config: Optional[bool] = None,
                      host_name: Optional[str] = None,
                      image_id: Optional[str] = None,
                      image_owner_alias: Optional[str] = None,
                      instance_charge_type: Optional[str] = None,
                      instance_name: Optional[str] = None,
                      instance_type: Optional[str] = None,
                      internet_charge_type: Optional[str] = None,
                      internet_max_bandwidth_in: Optional[int] = None,
                      internet_max_bandwidth_out: Optional[int] = None,
                      io_optimized: Optional[str] = None,
                      key_pair_name: Optional[str] = None,
                      launch_template_name: Optional[str] = None,
                      name: Optional[str] = None,
                      network_interfaces: Optional[EcsLaunchTemplateNetworkInterfacesArgs] = None,
                      network_type: Optional[str] = None,
                      password_inherit: Optional[bool] = None,
                      period: Optional[int] = None,
                      private_ip_address: Optional[str] = None,
                      ram_role_name: Optional[str] = None,
                      resource_group_id: Optional[str] = None,
                      security_enhancement_strategy: Optional[str] = None,
                      security_group_id: Optional[str] = None,
                      security_group_ids: Optional[Sequence[str]] = None,
                      spot_duration: Optional[str] = None,
                      spot_price_limit: Optional[float] = None,
                      spot_strategy: Optional[str] = None,
                      system_disk: Optional[EcsLaunchTemplateSystemDiskArgs] = None,
                      system_disk_category: Optional[str] = None,
                      system_disk_description: Optional[str] = None,
                      system_disk_name: Optional[str] = None,
                      system_disk_size: Optional[int] = None,
                      tags: Optional[Mapping[str, Any]] = None,
                      template_resource_group_id: Optional[str] = None,
                      template_tags: Optional[Mapping[str, Any]] = None,
                      user_data: Optional[str] = None,
                      userdata: Optional[str] = None,
                      version_description: Optional[str] = None,
                      vpc_id: Optional[str] = None,
                      vswitch_id: Optional[str] = None,
                      zone_id: Optional[str] = None)
@overload
def EcsLaunchTemplate(resource_name: str,
                      args: Optional[EcsLaunchTemplateArgs] = None,
                      opts: Optional[ResourceOptions] = None)
func NewEcsLaunchTemplate(ctx *Context, name string, args *EcsLaunchTemplateArgs, opts ...ResourceOption) (*EcsLaunchTemplate, error)
public EcsLaunchTemplate(string name, EcsLaunchTemplateArgs? args = null, CustomResourceOptions? opts = null)
public EcsLaunchTemplate(String name, EcsLaunchTemplateArgs args)
public EcsLaunchTemplate(String name, EcsLaunchTemplateArgs args, CustomResourceOptions options)
type: alicloud:ecs:EcsLaunchTemplate
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

name string
The unique name of the resource.
args EcsLaunchTemplateArgs
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 EcsLaunchTemplateArgs
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 EcsLaunchTemplateArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name string
The unique name of the resource.
args EcsLaunchTemplateArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name String
The unique name of the resource.
args EcsLaunchTemplateArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

EcsLaunchTemplate Resource Properties

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

Inputs

The EcsLaunchTemplate resource accepts the following input properties:

AutoReleaseTime string

Instance auto release time. The time is presented using the ISO8601 standard and in UTC time. The format is YYYY-MM-DDTHH:MM:SSZ.

DataDisks List<Pulumi.AliCloud.Ecs.Inputs.EcsLaunchTemplateDataDiskArgs>

The list of data disks created with instance.

DeploymentSetId string

The Deployment Set Id.

Description string

The description of the data disk.

EnableVmOsConfig bool

Whether to enable the instance operating system configuration.

HostName string

Instance host name.It cannot start or end with a period (.) or a hyphen (-) and it cannot have two or more consecutive periods (.) or hyphens (-).For Windows: The host name can be [2, 15] characters in length. It can contain A-Z, a-z, numbers, periods (.), and hyphens (-). It cannot only contain numbers. For other operating systems: The host name can be [2, 64] characters in length. It can be segments separated by periods (.). It can contain A-Z, a-z, numbers, and hyphens (-).

ImageId string

The Image ID.

ImageOwnerAlias string

Mirror source. Valid values: system, self, others, marketplace, "". Default to: "".

InstanceChargeType string

Billing methods. Valid values: PostPaid, PrePaid.

InstanceName string
InstanceType string

Instance type. For more information, call resource_alicloud_instances to obtain the latest instance type list.

InternetChargeType string

Internet bandwidth billing method. Valid values: PayByTraffic, PayByBandwidth.

InternetMaxBandwidthIn int

The maximum inbound bandwidth from the Internet network, measured in Mbit/s. Value range: [1, 200].

InternetMaxBandwidthOut int

Maximum outbound bandwidth from the Internet, its unit of measurement is Mbit/s. Value range: [0, 100].

IoOptimized string

Whether it is an I/O-optimized instance or not. Valid values: none, optimized.

KeyPairName string

The name of the key pair.

  • Ignore this parameter for Windows instances. It is null by default. Even if you enter this parameter, only the Password content is used.
  • The password logon method for Linux instances is set to forbidden upon initialization.
LaunchTemplateName string

The name of Launch Template.

Name string

The name of the data disk.

Deprecated:

Field 'name' has been deprecated from provider version 1.120.0. New field 'launch_template_name' instead.

NetworkInterfaces Pulumi.AliCloud.Ecs.Inputs.EcsLaunchTemplateNetworkInterfacesArgs

The list of network interfaces created with instance.

NetworkType string

Network type of the instance. Valid values: classic, vpc.

PasswordInherit bool

Whether to use the password preset by the mirror.

Period int

The subscription period of the instance. Unit: months. This parameter takes effect and is required only when InstanceChargeType is set to PrePaid. If the DedicatedHostId parameter is specified, the value of the Period parameter must be within the subscription period of the dedicated host.

  • When the PeriodUnit parameter is set to Week, the valid values of the Period parameter are 1, 2, 3, and 4.
  • When the PeriodUnit parameter is set to Month, the valid values of the Period parameter are 1, 2, 3, 4, 5, 6, 7, 8, 9, 12, 24, 36, 48, and 60.
PrivateIpAddress string

The private IP address of the instance.

RamRoleName string

The RAM role name of the instance. You can use the RAM API ListRoles to query instance RAM role names.

ResourceGroupId string

The ID of the resource group to which to assign the instance, Elastic Block Storage (EBS) device, and ENI.

SecurityEnhancementStrategy string

Whether or not to activate the security enhancement feature and install network security software free of charge. Valid values: Active, Deactive.

SecurityGroupId string

The security group ID must be one in the same VPC.

SecurityGroupIds List<string>

The ID of security group N to which to assign the instance.

SpotDuration string

The protection period of the preemptible instance. Unit: hours. Valid values: 0, 1, 2, 3, 4, 5, and 6. Default to: 1.

SpotPriceLimit double

-(Optional) Sets the maximum hourly instance price. Supports up to three decimal places.

SpotStrategy string

The spot strategy for a Pay-As-You-Go instance. This parameter is valid and required only when InstanceChargeType is set to PostPaid. Valid values: NoSpot, SpotAsPriceGo, SpotWithPriceLimit.

SystemDisk Pulumi.AliCloud.Ecs.Inputs.EcsLaunchTemplateSystemDiskArgs

The System Disk.

SystemDiskCategory string

Deprecated:

Field 'system_disk_category' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

SystemDiskDescription string

Deprecated:

Field 'system_disk_description' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

SystemDiskName string

Deprecated:

Field 'system_disk_name' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

SystemDiskSize int

Deprecated:

Field 'system_disk_size' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

Tags Dictionary<string, object>

A mapping of tags to assign to instance, block storage, and elastic network.

  • Key: It can be up to 64 characters in length. It cannot begin with "aliyun", "acs:", "http://", or "https://". It cannot be a null string.
  • Value: It can be up to 128 characters in length. It cannot begin with "aliyun", "acs:", "http://", or "https://". It can be a null string.
TemplateResourceGroupId string

The template resource group id.

TemplateTags Dictionary<string, object>

A mapping of tags to assign to the launch template.

UserData string

The User Data.

Userdata string

Deprecated:

Field 'userdata' has been deprecated from provider version 1.120.0. New field 'user_data' instead.

VersionDescription string

The description of the launch template version. The description must be 2 to 256 characters in length and cannot start with http:// or https://.

VpcId string
VswitchId string

The VSwitch ID for ENI. The instance must be in the same zone of the same VPC network as the ENI, but they may belong to different VSwitches.

ZoneId string

The zone ID of the instance.

AutoReleaseTime string

Instance auto release time. The time is presented using the ISO8601 standard and in UTC time. The format is YYYY-MM-DDTHH:MM:SSZ.

DataDisks []EcsLaunchTemplateDataDiskArgs

The list of data disks created with instance.

DeploymentSetId string

The Deployment Set Id.

Description string

The description of the data disk.

EnableVmOsConfig bool

Whether to enable the instance operating system configuration.

HostName string

Instance host name.It cannot start or end with a period (.) or a hyphen (-) and it cannot have two or more consecutive periods (.) or hyphens (-).For Windows: The host name can be [2, 15] characters in length. It can contain A-Z, a-z, numbers, periods (.), and hyphens (-). It cannot only contain numbers. For other operating systems: The host name can be [2, 64] characters in length. It can be segments separated by periods (.). It can contain A-Z, a-z, numbers, and hyphens (-).

ImageId string

The Image ID.

ImageOwnerAlias string

Mirror source. Valid values: system, self, others, marketplace, "". Default to: "".

InstanceChargeType string

Billing methods. Valid values: PostPaid, PrePaid.

InstanceName string
InstanceType string

Instance type. For more information, call resource_alicloud_instances to obtain the latest instance type list.

InternetChargeType string

Internet bandwidth billing method. Valid values: PayByTraffic, PayByBandwidth.

InternetMaxBandwidthIn int

The maximum inbound bandwidth from the Internet network, measured in Mbit/s. Value range: [1, 200].

InternetMaxBandwidthOut int

Maximum outbound bandwidth from the Internet, its unit of measurement is Mbit/s. Value range: [0, 100].

IoOptimized string

Whether it is an I/O-optimized instance or not. Valid values: none, optimized.

KeyPairName string

The name of the key pair.

  • Ignore this parameter for Windows instances. It is null by default. Even if you enter this parameter, only the Password content is used.
  • The password logon method for Linux instances is set to forbidden upon initialization.
LaunchTemplateName string

The name of Launch Template.

Name string

The name of the data disk.

Deprecated:

Field 'name' has been deprecated from provider version 1.120.0. New field 'launch_template_name' instead.

NetworkInterfaces EcsLaunchTemplateNetworkInterfacesArgs

The list of network interfaces created with instance.

NetworkType string

Network type of the instance. Valid values: classic, vpc.

PasswordInherit bool

Whether to use the password preset by the mirror.

Period int

The subscription period of the instance. Unit: months. This parameter takes effect and is required only when InstanceChargeType is set to PrePaid. If the DedicatedHostId parameter is specified, the value of the Period parameter must be within the subscription period of the dedicated host.

  • When the PeriodUnit parameter is set to Week, the valid values of the Period parameter are 1, 2, 3, and 4.
  • When the PeriodUnit parameter is set to Month, the valid values of the Period parameter are 1, 2, 3, 4, 5, 6, 7, 8, 9, 12, 24, 36, 48, and 60.
PrivateIpAddress string

The private IP address of the instance.

RamRoleName string

The RAM role name of the instance. You can use the RAM API ListRoles to query instance RAM role names.

ResourceGroupId string

The ID of the resource group to which to assign the instance, Elastic Block Storage (EBS) device, and ENI.

SecurityEnhancementStrategy string

Whether or not to activate the security enhancement feature and install network security software free of charge. Valid values: Active, Deactive.

SecurityGroupId string

The security group ID must be one in the same VPC.

SecurityGroupIds []string

The ID of security group N to which to assign the instance.

SpotDuration string

The protection period of the preemptible instance. Unit: hours. Valid values: 0, 1, 2, 3, 4, 5, and 6. Default to: 1.

SpotPriceLimit float64

-(Optional) Sets the maximum hourly instance price. Supports up to three decimal places.

SpotStrategy string

The spot strategy for a Pay-As-You-Go instance. This parameter is valid and required only when InstanceChargeType is set to PostPaid. Valid values: NoSpot, SpotAsPriceGo, SpotWithPriceLimit.

SystemDisk EcsLaunchTemplateSystemDiskArgs

The System Disk.

SystemDiskCategory string

Deprecated:

Field 'system_disk_category' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

SystemDiskDescription string

Deprecated:

Field 'system_disk_description' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

SystemDiskName string

Deprecated:

Field 'system_disk_name' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

SystemDiskSize int

Deprecated:

Field 'system_disk_size' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

Tags map[string]interface{}

A mapping of tags to assign to instance, block storage, and elastic network.

  • Key: It can be up to 64 characters in length. It cannot begin with "aliyun", "acs:", "http://", or "https://". It cannot be a null string.
  • Value: It can be up to 128 characters in length. It cannot begin with "aliyun", "acs:", "http://", or "https://". It can be a null string.
TemplateResourceGroupId string

The template resource group id.

TemplateTags map[string]interface{}

A mapping of tags to assign to the launch template.

UserData string

The User Data.

Userdata string

Deprecated:

Field 'userdata' has been deprecated from provider version 1.120.0. New field 'user_data' instead.

VersionDescription string

The description of the launch template version. The description must be 2 to 256 characters in length and cannot start with http:// or https://.

VpcId string
VswitchId string

The VSwitch ID for ENI. The instance must be in the same zone of the same VPC network as the ENI, but they may belong to different VSwitches.

ZoneId string

The zone ID of the instance.

autoReleaseTime String

Instance auto release time. The time is presented using the ISO8601 standard and in UTC time. The format is YYYY-MM-DDTHH:MM:SSZ.

dataDisks List<EcsLaunchTemplateDataDiskArgs>

The list of data disks created with instance.

deploymentSetId String

The Deployment Set Id.

description String

The description of the data disk.

enableVmOsConfig Boolean

Whether to enable the instance operating system configuration.

hostName String

Instance host name.It cannot start or end with a period (.) or a hyphen (-) and it cannot have two or more consecutive periods (.) or hyphens (-).For Windows: The host name can be [2, 15] characters in length. It can contain A-Z, a-z, numbers, periods (.), and hyphens (-). It cannot only contain numbers. For other operating systems: The host name can be [2, 64] characters in length. It can be segments separated by periods (.). It can contain A-Z, a-z, numbers, and hyphens (-).

imageId String

The Image ID.

imageOwnerAlias String

Mirror source. Valid values: system, self, others, marketplace, "". Default to: "".

instanceChargeType String

Billing methods. Valid values: PostPaid, PrePaid.

instanceName String
instanceType String

Instance type. For more information, call resource_alicloud_instances to obtain the latest instance type list.

internetChargeType String

Internet bandwidth billing method. Valid values: PayByTraffic, PayByBandwidth.

internetMaxBandwidthIn Integer

The maximum inbound bandwidth from the Internet network, measured in Mbit/s. Value range: [1, 200].

internetMaxBandwidthOut Integer

Maximum outbound bandwidth from the Internet, its unit of measurement is Mbit/s. Value range: [0, 100].

ioOptimized String

Whether it is an I/O-optimized instance or not. Valid values: none, optimized.

keyPairName String

The name of the key pair.

  • Ignore this parameter for Windows instances. It is null by default. Even if you enter this parameter, only the Password content is used.
  • The password logon method for Linux instances is set to forbidden upon initialization.
launchTemplateName String

The name of Launch Template.

name String

The name of the data disk.

Deprecated:

Field 'name' has been deprecated from provider version 1.120.0. New field 'launch_template_name' instead.

networkInterfaces EcsLaunchTemplateNetworkInterfacesArgs

The list of network interfaces created with instance.

networkType String

Network type of the instance. Valid values: classic, vpc.

passwordInherit Boolean

Whether to use the password preset by the mirror.

period Integer

The subscription period of the instance. Unit: months. This parameter takes effect and is required only when InstanceChargeType is set to PrePaid. If the DedicatedHostId parameter is specified, the value of the Period parameter must be within the subscription period of the dedicated host.

  • When the PeriodUnit parameter is set to Week, the valid values of the Period parameter are 1, 2, 3, and 4.
  • When the PeriodUnit parameter is set to Month, the valid values of the Period parameter are 1, 2, 3, 4, 5, 6, 7, 8, 9, 12, 24, 36, 48, and 60.
privateIpAddress String

The private IP address of the instance.

ramRoleName String

The RAM role name of the instance. You can use the RAM API ListRoles to query instance RAM role names.

resourceGroupId String

The ID of the resource group to which to assign the instance, Elastic Block Storage (EBS) device, and ENI.

securityEnhancementStrategy String

Whether or not to activate the security enhancement feature and install network security software free of charge. Valid values: Active, Deactive.

securityGroupId String

The security group ID must be one in the same VPC.

securityGroupIds List<String>

The ID of security group N to which to assign the instance.

spotDuration String

The protection period of the preemptible instance. Unit: hours. Valid values: 0, 1, 2, 3, 4, 5, and 6. Default to: 1.

spotPriceLimit Double

-(Optional) Sets the maximum hourly instance price. Supports up to three decimal places.

spotStrategy String

The spot strategy for a Pay-As-You-Go instance. This parameter is valid and required only when InstanceChargeType is set to PostPaid. Valid values: NoSpot, SpotAsPriceGo, SpotWithPriceLimit.

systemDisk EcsLaunchTemplateSystemDiskArgs

The System Disk.

systemDiskCategory String

Deprecated:

Field 'system_disk_category' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

systemDiskDescription String

Deprecated:

Field 'system_disk_description' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

systemDiskName String

Deprecated:

Field 'system_disk_name' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

systemDiskSize Integer

Deprecated:

Field 'system_disk_size' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

tags Map<String,Object>

A mapping of tags to assign to instance, block storage, and elastic network.

  • Key: It can be up to 64 characters in length. It cannot begin with "aliyun", "acs:", "http://", or "https://". It cannot be a null string.
  • Value: It can be up to 128 characters in length. It cannot begin with "aliyun", "acs:", "http://", or "https://". It can be a null string.
templateResourceGroupId String

The template resource group id.

templateTags Map<String,Object>

A mapping of tags to assign to the launch template.

userData String

The User Data.

userdata String

Deprecated:

Field 'userdata' has been deprecated from provider version 1.120.0. New field 'user_data' instead.

versionDescription String

The description of the launch template version. The description must be 2 to 256 characters in length and cannot start with http:// or https://.

vpcId String
vswitchId String

The VSwitch ID for ENI. The instance must be in the same zone of the same VPC network as the ENI, but they may belong to different VSwitches.

zoneId String

The zone ID of the instance.

autoReleaseTime string

Instance auto release time. The time is presented using the ISO8601 standard and in UTC time. The format is YYYY-MM-DDTHH:MM:SSZ.

dataDisks EcsLaunchTemplateDataDiskArgs[]

The list of data disks created with instance.

deploymentSetId string

The Deployment Set Id.

description string

The description of the data disk.

enableVmOsConfig boolean

Whether to enable the instance operating system configuration.

hostName string

Instance host name.It cannot start or end with a period (.) or a hyphen (-) and it cannot have two or more consecutive periods (.) or hyphens (-).For Windows: The host name can be [2, 15] characters in length. It can contain A-Z, a-z, numbers, periods (.), and hyphens (-). It cannot only contain numbers. For other operating systems: The host name can be [2, 64] characters in length. It can be segments separated by periods (.). It can contain A-Z, a-z, numbers, and hyphens (-).

imageId string

The Image ID.

imageOwnerAlias string

Mirror source. Valid values: system, self, others, marketplace, "". Default to: "".

instanceChargeType string

Billing methods. Valid values: PostPaid, PrePaid.

instanceName string
instanceType string

Instance type. For more information, call resource_alicloud_instances to obtain the latest instance type list.

internetChargeType string

Internet bandwidth billing method. Valid values: PayByTraffic, PayByBandwidth.

internetMaxBandwidthIn number

The maximum inbound bandwidth from the Internet network, measured in Mbit/s. Value range: [1, 200].

internetMaxBandwidthOut number

Maximum outbound bandwidth from the Internet, its unit of measurement is Mbit/s. Value range: [0, 100].

ioOptimized string

Whether it is an I/O-optimized instance or not. Valid values: none, optimized.

keyPairName string

The name of the key pair.

  • Ignore this parameter for Windows instances. It is null by default. Even if you enter this parameter, only the Password content is used.
  • The password logon method for Linux instances is set to forbidden upon initialization.
launchTemplateName string

The name of Launch Template.

name string

The name of the data disk.

Deprecated:

Field 'name' has been deprecated from provider version 1.120.0. New field 'launch_template_name' instead.

networkInterfaces EcsLaunchTemplateNetworkInterfacesArgs

The list of network interfaces created with instance.

networkType string

Network type of the instance. Valid values: classic, vpc.

passwordInherit boolean

Whether to use the password preset by the mirror.

period number

The subscription period of the instance. Unit: months. This parameter takes effect and is required only when InstanceChargeType is set to PrePaid. If the DedicatedHostId parameter is specified, the value of the Period parameter must be within the subscription period of the dedicated host.

  • When the PeriodUnit parameter is set to Week, the valid values of the Period parameter are 1, 2, 3, and 4.
  • When the PeriodUnit parameter is set to Month, the valid values of the Period parameter are 1, 2, 3, 4, 5, 6, 7, 8, 9, 12, 24, 36, 48, and 60.
privateIpAddress string

The private IP address of the instance.

ramRoleName string

The RAM role name of the instance. You can use the RAM API ListRoles to query instance RAM role names.

resourceGroupId string

The ID of the resource group to which to assign the instance, Elastic Block Storage (EBS) device, and ENI.

securityEnhancementStrategy string

Whether or not to activate the security enhancement feature and install network security software free of charge. Valid values: Active, Deactive.

securityGroupId string

The security group ID must be one in the same VPC.

securityGroupIds string[]

The ID of security group N to which to assign the instance.

spotDuration string

The protection period of the preemptible instance. Unit: hours. Valid values: 0, 1, 2, 3, 4, 5, and 6. Default to: 1.

spotPriceLimit number

-(Optional) Sets the maximum hourly instance price. Supports up to three decimal places.

spotStrategy string

The spot strategy for a Pay-As-You-Go instance. This parameter is valid and required only when InstanceChargeType is set to PostPaid. Valid values: NoSpot, SpotAsPriceGo, SpotWithPriceLimit.

systemDisk EcsLaunchTemplateSystemDiskArgs

The System Disk.

systemDiskCategory string

Deprecated:

Field 'system_disk_category' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

systemDiskDescription string

Deprecated:

Field 'system_disk_description' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

systemDiskName string

Deprecated:

Field 'system_disk_name' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

systemDiskSize number

Deprecated:

Field 'system_disk_size' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

tags {[key: string]: any}

A mapping of tags to assign to instance, block storage, and elastic network.

  • Key: It can be up to 64 characters in length. It cannot begin with "aliyun", "acs:", "http://", or "https://". It cannot be a null string.
  • Value: It can be up to 128 characters in length. It cannot begin with "aliyun", "acs:", "http://", or "https://". It can be a null string.
templateResourceGroupId string

The template resource group id.

templateTags {[key: string]: any}

A mapping of tags to assign to the launch template.

userData string

The User Data.

userdata string

Deprecated:

Field 'userdata' has been deprecated from provider version 1.120.0. New field 'user_data' instead.

versionDescription string

The description of the launch template version. The description must be 2 to 256 characters in length and cannot start with http:// or https://.

vpcId string
vswitchId string

The VSwitch ID for ENI. The instance must be in the same zone of the same VPC network as the ENI, but they may belong to different VSwitches.

zoneId string

The zone ID of the instance.

auto_release_time str

Instance auto release time. The time is presented using the ISO8601 standard and in UTC time. The format is YYYY-MM-DDTHH:MM:SSZ.

data_disks Sequence[EcsLaunchTemplateDataDiskArgs]

The list of data disks created with instance.

deployment_set_id str

The Deployment Set Id.

description str

The description of the data disk.

enable_vm_os_config bool

Whether to enable the instance operating system configuration.

host_name str

Instance host name.It cannot start or end with a period (.) or a hyphen (-) and it cannot have two or more consecutive periods (.) or hyphens (-).For Windows: The host name can be [2, 15] characters in length. It can contain A-Z, a-z, numbers, periods (.), and hyphens (-). It cannot only contain numbers. For other operating systems: The host name can be [2, 64] characters in length. It can be segments separated by periods (.). It can contain A-Z, a-z, numbers, and hyphens (-).

image_id str

The Image ID.

image_owner_alias str

Mirror source. Valid values: system, self, others, marketplace, "". Default to: "".

instance_charge_type str

Billing methods. Valid values: PostPaid, PrePaid.

instance_name str
instance_type str

Instance type. For more information, call resource_alicloud_instances to obtain the latest instance type list.

internet_charge_type str

Internet bandwidth billing method. Valid values: PayByTraffic, PayByBandwidth.

internet_max_bandwidth_in int

The maximum inbound bandwidth from the Internet network, measured in Mbit/s. Value range: [1, 200].

internet_max_bandwidth_out int

Maximum outbound bandwidth from the Internet, its unit of measurement is Mbit/s. Value range: [0, 100].

io_optimized str

Whether it is an I/O-optimized instance or not. Valid values: none, optimized.

key_pair_name str

The name of the key pair.

  • Ignore this parameter for Windows instances. It is null by default. Even if you enter this parameter, only the Password content is used.
  • The password logon method for Linux instances is set to forbidden upon initialization.
launch_template_name str

The name of Launch Template.

name str

The name of the data disk.

Deprecated:

Field 'name' has been deprecated from provider version 1.120.0. New field 'launch_template_name' instead.

network_interfaces EcsLaunchTemplateNetworkInterfacesArgs

The list of network interfaces created with instance.

network_type str

Network type of the instance. Valid values: classic, vpc.

password_inherit bool

Whether to use the password preset by the mirror.

period int

The subscription period of the instance. Unit: months. This parameter takes effect and is required only when InstanceChargeType is set to PrePaid. If the DedicatedHostId parameter is specified, the value of the Period parameter must be within the subscription period of the dedicated host.

  • When the PeriodUnit parameter is set to Week, the valid values of the Period parameter are 1, 2, 3, and 4.
  • When the PeriodUnit parameter is set to Month, the valid values of the Period parameter are 1, 2, 3, 4, 5, 6, 7, 8, 9, 12, 24, 36, 48, and 60.
private_ip_address str

The private IP address of the instance.

ram_role_name str

The RAM role name of the instance. You can use the RAM API ListRoles to query instance RAM role names.

resource_group_id str

The ID of the resource group to which to assign the instance, Elastic Block Storage (EBS) device, and ENI.

security_enhancement_strategy str

Whether or not to activate the security enhancement feature and install network security software free of charge. Valid values: Active, Deactive.

security_group_id str

The security group ID must be one in the same VPC.

security_group_ids Sequence[str]

The ID of security group N to which to assign the instance.

spot_duration str

The protection period of the preemptible instance. Unit: hours. Valid values: 0, 1, 2, 3, 4, 5, and 6. Default to: 1.

spot_price_limit float

-(Optional) Sets the maximum hourly instance price. Supports up to three decimal places.

spot_strategy str

The spot strategy for a Pay-As-You-Go instance. This parameter is valid and required only when InstanceChargeType is set to PostPaid. Valid values: NoSpot, SpotAsPriceGo, SpotWithPriceLimit.

system_disk EcsLaunchTemplateSystemDiskArgs

The System Disk.

system_disk_category str

Deprecated:

Field 'system_disk_category' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

system_disk_description str

Deprecated:

Field 'system_disk_description' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

system_disk_name str

Deprecated:

Field 'system_disk_name' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

system_disk_size int

Deprecated:

Field 'system_disk_size' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

tags Mapping[str, Any]

A mapping of tags to assign to instance, block storage, and elastic network.

  • Key: It can be up to 64 characters in length. It cannot begin with "aliyun", "acs:", "http://", or "https://". It cannot be a null string.
  • Value: It can be up to 128 characters in length. It cannot begin with "aliyun", "acs:", "http://", or "https://". It can be a null string.
template_resource_group_id str

The template resource group id.

template_tags Mapping[str, Any]

A mapping of tags to assign to the launch template.

user_data str

The User Data.

userdata str

Deprecated:

Field 'userdata' has been deprecated from provider version 1.120.0. New field 'user_data' instead.

version_description str

The description of the launch template version. The description must be 2 to 256 characters in length and cannot start with http:// or https://.

vpc_id str
vswitch_id str

The VSwitch ID for ENI. The instance must be in the same zone of the same VPC network as the ENI, but they may belong to different VSwitches.

zone_id str

The zone ID of the instance.

autoReleaseTime String

Instance auto release time. The time is presented using the ISO8601 standard and in UTC time. The format is YYYY-MM-DDTHH:MM:SSZ.

dataDisks List<Property Map>

The list of data disks created with instance.

deploymentSetId String

The Deployment Set Id.

description String

The description of the data disk.

enableVmOsConfig Boolean

Whether to enable the instance operating system configuration.

hostName String

Instance host name.It cannot start or end with a period (.) or a hyphen (-) and it cannot have two or more consecutive periods (.) or hyphens (-).For Windows: The host name can be [2, 15] characters in length. It can contain A-Z, a-z, numbers, periods (.), and hyphens (-). It cannot only contain numbers. For other operating systems: The host name can be [2, 64] characters in length. It can be segments separated by periods (.). It can contain A-Z, a-z, numbers, and hyphens (-).

imageId String

The Image ID.

imageOwnerAlias String

Mirror source. Valid values: system, self, others, marketplace, "". Default to: "".

instanceChargeType String

Billing methods. Valid values: PostPaid, PrePaid.

instanceName String
instanceType String

Instance type. For more information, call resource_alicloud_instances to obtain the latest instance type list.

internetChargeType String

Internet bandwidth billing method. Valid values: PayByTraffic, PayByBandwidth.

internetMaxBandwidthIn Number

The maximum inbound bandwidth from the Internet network, measured in Mbit/s. Value range: [1, 200].

internetMaxBandwidthOut Number

Maximum outbound bandwidth from the Internet, its unit of measurement is Mbit/s. Value range: [0, 100].

ioOptimized String

Whether it is an I/O-optimized instance or not. Valid values: none, optimized.

keyPairName String

The name of the key pair.

  • Ignore this parameter for Windows instances. It is null by default. Even if you enter this parameter, only the Password content is used.
  • The password logon method for Linux instances is set to forbidden upon initialization.
launchTemplateName String

The name of Launch Template.

name String

The name of the data disk.

Deprecated:

Field 'name' has been deprecated from provider version 1.120.0. New field 'launch_template_name' instead.

networkInterfaces Property Map

The list of network interfaces created with instance.

networkType String

Network type of the instance. Valid values: classic, vpc.

passwordInherit Boolean

Whether to use the password preset by the mirror.

period Number

The subscription period of the instance. Unit: months. This parameter takes effect and is required only when InstanceChargeType is set to PrePaid. If the DedicatedHostId parameter is specified, the value of the Period parameter must be within the subscription period of the dedicated host.

  • When the PeriodUnit parameter is set to Week, the valid values of the Period parameter are 1, 2, 3, and 4.
  • When the PeriodUnit parameter is set to Month, the valid values of the Period parameter are 1, 2, 3, 4, 5, 6, 7, 8, 9, 12, 24, 36, 48, and 60.
privateIpAddress String

The private IP address of the instance.

ramRoleName String

The RAM role name of the instance. You can use the RAM API ListRoles to query instance RAM role names.

resourceGroupId String

The ID of the resource group to which to assign the instance, Elastic Block Storage (EBS) device, and ENI.

securityEnhancementStrategy String

Whether or not to activate the security enhancement feature and install network security software free of charge. Valid values: Active, Deactive.

securityGroupId String

The security group ID must be one in the same VPC.

securityGroupIds List<String>

The ID of security group N to which to assign the instance.

spotDuration String

The protection period of the preemptible instance. Unit: hours. Valid values: 0, 1, 2, 3, 4, 5, and 6. Default to: 1.

spotPriceLimit Number

-(Optional) Sets the maximum hourly instance price. Supports up to three decimal places.

spotStrategy String

The spot strategy for a Pay-As-You-Go instance. This parameter is valid and required only when InstanceChargeType is set to PostPaid. Valid values: NoSpot, SpotAsPriceGo, SpotWithPriceLimit.

systemDisk Property Map

The System Disk.

systemDiskCategory String

Deprecated:

Field 'system_disk_category' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

systemDiskDescription String

Deprecated:

Field 'system_disk_description' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

systemDiskName String

Deprecated:

Field 'system_disk_name' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

systemDiskSize Number

Deprecated:

Field 'system_disk_size' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

tags Map<Any>

A mapping of tags to assign to instance, block storage, and elastic network.

  • Key: It can be up to 64 characters in length. It cannot begin with "aliyun", "acs:", "http://", or "https://". It cannot be a null string.
  • Value: It can be up to 128 characters in length. It cannot begin with "aliyun", "acs:", "http://", or "https://". It can be a null string.
templateResourceGroupId String

The template resource group id.

templateTags Map<Any>

A mapping of tags to assign to the launch template.

userData String

The User Data.

userdata String

Deprecated:

Field 'userdata' has been deprecated from provider version 1.120.0. New field 'user_data' instead.

versionDescription String

The description of the launch template version. The description must be 2 to 256 characters in length and cannot start with http:// or https://.

vpcId String
vswitchId String

The VSwitch ID for ENI. The instance must be in the same zone of the same VPC network as the ENI, but they may belong to different VSwitches.

zoneId String

The zone ID of the instance.

Outputs

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

Id string

The provider-assigned unique ID for this managed resource.

Id string

The provider-assigned unique ID for this managed resource.

id String

The provider-assigned unique ID for this managed resource.

id string

The provider-assigned unique ID for this managed resource.

id str

The provider-assigned unique ID for this managed resource.

id String

The provider-assigned unique ID for this managed resource.

Look up an Existing EcsLaunchTemplate Resource

Get an existing EcsLaunchTemplate 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?: EcsLaunchTemplateState, opts?: CustomResourceOptions): EcsLaunchTemplate
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        auto_release_time: Optional[str] = None,
        data_disks: Optional[Sequence[EcsLaunchTemplateDataDiskArgs]] = None,
        deployment_set_id: Optional[str] = None,
        description: Optional[str] = None,
        enable_vm_os_config: Optional[bool] = None,
        host_name: Optional[str] = None,
        image_id: Optional[str] = None,
        image_owner_alias: Optional[str] = None,
        instance_charge_type: Optional[str] = None,
        instance_name: Optional[str] = None,
        instance_type: Optional[str] = None,
        internet_charge_type: Optional[str] = None,
        internet_max_bandwidth_in: Optional[int] = None,
        internet_max_bandwidth_out: Optional[int] = None,
        io_optimized: Optional[str] = None,
        key_pair_name: Optional[str] = None,
        launch_template_name: Optional[str] = None,
        name: Optional[str] = None,
        network_interfaces: Optional[EcsLaunchTemplateNetworkInterfacesArgs] = None,
        network_type: Optional[str] = None,
        password_inherit: Optional[bool] = None,
        period: Optional[int] = None,
        private_ip_address: Optional[str] = None,
        ram_role_name: Optional[str] = None,
        resource_group_id: Optional[str] = None,
        security_enhancement_strategy: Optional[str] = None,
        security_group_id: Optional[str] = None,
        security_group_ids: Optional[Sequence[str]] = None,
        spot_duration: Optional[str] = None,
        spot_price_limit: Optional[float] = None,
        spot_strategy: Optional[str] = None,
        system_disk: Optional[EcsLaunchTemplateSystemDiskArgs] = None,
        system_disk_category: Optional[str] = None,
        system_disk_description: Optional[str] = None,
        system_disk_name: Optional[str] = None,
        system_disk_size: Optional[int] = None,
        tags: Optional[Mapping[str, Any]] = None,
        template_resource_group_id: Optional[str] = None,
        template_tags: Optional[Mapping[str, Any]] = None,
        user_data: Optional[str] = None,
        userdata: Optional[str] = None,
        version_description: Optional[str] = None,
        vpc_id: Optional[str] = None,
        vswitch_id: Optional[str] = None,
        zone_id: Optional[str] = None) -> EcsLaunchTemplate
func GetEcsLaunchTemplate(ctx *Context, name string, id IDInput, state *EcsLaunchTemplateState, opts ...ResourceOption) (*EcsLaunchTemplate, error)
public static EcsLaunchTemplate Get(string name, Input<string> id, EcsLaunchTemplateState? state, CustomResourceOptions? opts = null)
public static EcsLaunchTemplate get(String name, Output<String> id, EcsLaunchTemplateState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
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:
AutoReleaseTime string

Instance auto release time. The time is presented using the ISO8601 standard and in UTC time. The format is YYYY-MM-DDTHH:MM:SSZ.

DataDisks List<Pulumi.AliCloud.Ecs.Inputs.EcsLaunchTemplateDataDiskArgs>

The list of data disks created with instance.

DeploymentSetId string

The Deployment Set Id.

Description string

The description of the data disk.

EnableVmOsConfig bool

Whether to enable the instance operating system configuration.

HostName string

Instance host name.It cannot start or end with a period (.) or a hyphen (-) and it cannot have two or more consecutive periods (.) or hyphens (-).For Windows: The host name can be [2, 15] characters in length. It can contain A-Z, a-z, numbers, periods (.), and hyphens (-). It cannot only contain numbers. For other operating systems: The host name can be [2, 64] characters in length. It can be segments separated by periods (.). It can contain A-Z, a-z, numbers, and hyphens (-).

ImageId string

The Image ID.

ImageOwnerAlias string

Mirror source. Valid values: system, self, others, marketplace, "". Default to: "".

InstanceChargeType string

Billing methods. Valid values: PostPaid, PrePaid.

InstanceName string
InstanceType string

Instance type. For more information, call resource_alicloud_instances to obtain the latest instance type list.

InternetChargeType string

Internet bandwidth billing method. Valid values: PayByTraffic, PayByBandwidth.

InternetMaxBandwidthIn int

The maximum inbound bandwidth from the Internet network, measured in Mbit/s. Value range: [1, 200].

InternetMaxBandwidthOut int

Maximum outbound bandwidth from the Internet, its unit of measurement is Mbit/s. Value range: [0, 100].

IoOptimized string

Whether it is an I/O-optimized instance or not. Valid values: none, optimized.

KeyPairName string

The name of the key pair.

  • Ignore this parameter for Windows instances. It is null by default. Even if you enter this parameter, only the Password content is used.
  • The password logon method for Linux instances is set to forbidden upon initialization.
LaunchTemplateName string

The name of Launch Template.

Name string

The name of the data disk.

Deprecated:

Field 'name' has been deprecated from provider version 1.120.0. New field 'launch_template_name' instead.

NetworkInterfaces Pulumi.AliCloud.Ecs.Inputs.EcsLaunchTemplateNetworkInterfacesArgs

The list of network interfaces created with instance.

NetworkType string

Network type of the instance. Valid values: classic, vpc.

PasswordInherit bool

Whether to use the password preset by the mirror.

Period int

The subscription period of the instance. Unit: months. This parameter takes effect and is required only when InstanceChargeType is set to PrePaid. If the DedicatedHostId parameter is specified, the value of the Period parameter must be within the subscription period of the dedicated host.

  • When the PeriodUnit parameter is set to Week, the valid values of the Period parameter are 1, 2, 3, and 4.
  • When the PeriodUnit parameter is set to Month, the valid values of the Period parameter are 1, 2, 3, 4, 5, 6, 7, 8, 9, 12, 24, 36, 48, and 60.
PrivateIpAddress string

The private IP address of the instance.

RamRoleName string

The RAM role name of the instance. You can use the RAM API ListRoles to query instance RAM role names.

ResourceGroupId string

The ID of the resource group to which to assign the instance, Elastic Block Storage (EBS) device, and ENI.

SecurityEnhancementStrategy string

Whether or not to activate the security enhancement feature and install network security software free of charge. Valid values: Active, Deactive.

SecurityGroupId string

The security group ID must be one in the same VPC.

SecurityGroupIds List<string>

The ID of security group N to which to assign the instance.

SpotDuration string

The protection period of the preemptible instance. Unit: hours. Valid values: 0, 1, 2, 3, 4, 5, and 6. Default to: 1.

SpotPriceLimit double

-(Optional) Sets the maximum hourly instance price. Supports up to three decimal places.

SpotStrategy string

The spot strategy for a Pay-As-You-Go instance. This parameter is valid and required only when InstanceChargeType is set to PostPaid. Valid values: NoSpot, SpotAsPriceGo, SpotWithPriceLimit.

SystemDisk Pulumi.AliCloud.Ecs.Inputs.EcsLaunchTemplateSystemDiskArgs

The System Disk.

SystemDiskCategory string

Deprecated:

Field 'system_disk_category' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

SystemDiskDescription string

Deprecated:

Field 'system_disk_description' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

SystemDiskName string

Deprecated:

Field 'system_disk_name' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

SystemDiskSize int

Deprecated:

Field 'system_disk_size' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

Tags Dictionary<string, object>

A mapping of tags to assign to instance, block storage, and elastic network.

  • Key: It can be up to 64 characters in length. It cannot begin with "aliyun", "acs:", "http://", or "https://". It cannot be a null string.
  • Value: It can be up to 128 characters in length. It cannot begin with "aliyun", "acs:", "http://", or "https://". It can be a null string.
TemplateResourceGroupId string

The template resource group id.

TemplateTags Dictionary<string, object>

A mapping of tags to assign to the launch template.

UserData string

The User Data.

Userdata string

Deprecated:

Field 'userdata' has been deprecated from provider version 1.120.0. New field 'user_data' instead.

VersionDescription string

The description of the launch template version. The description must be 2 to 256 characters in length and cannot start with http:// or https://.

VpcId string
VswitchId string

The VSwitch ID for ENI. The instance must be in the same zone of the same VPC network as the ENI, but they may belong to different VSwitches.

ZoneId string

The zone ID of the instance.

AutoReleaseTime string

Instance auto release time. The time is presented using the ISO8601 standard and in UTC time. The format is YYYY-MM-DDTHH:MM:SSZ.

DataDisks []EcsLaunchTemplateDataDiskArgs

The list of data disks created with instance.

DeploymentSetId string

The Deployment Set Id.

Description string

The description of the data disk.

EnableVmOsConfig bool

Whether to enable the instance operating system configuration.

HostName string

Instance host name.It cannot start or end with a period (.) or a hyphen (-) and it cannot have two or more consecutive periods (.) or hyphens (-).For Windows: The host name can be [2, 15] characters in length. It can contain A-Z, a-z, numbers, periods (.), and hyphens (-). It cannot only contain numbers. For other operating systems: The host name can be [2, 64] characters in length. It can be segments separated by periods (.). It can contain A-Z, a-z, numbers, and hyphens (-).

ImageId string

The Image ID.

ImageOwnerAlias string

Mirror source. Valid values: system, self, others, marketplace, "". Default to: "".

InstanceChargeType string

Billing methods. Valid values: PostPaid, PrePaid.

InstanceName string
InstanceType string

Instance type. For more information, call resource_alicloud_instances to obtain the latest instance type list.

InternetChargeType string

Internet bandwidth billing method. Valid values: PayByTraffic, PayByBandwidth.

InternetMaxBandwidthIn int

The maximum inbound bandwidth from the Internet network, measured in Mbit/s. Value range: [1, 200].

InternetMaxBandwidthOut int

Maximum outbound bandwidth from the Internet, its unit of measurement is Mbit/s. Value range: [0, 100].

IoOptimized string

Whether it is an I/O-optimized instance or not. Valid values: none, optimized.

KeyPairName string

The name of the key pair.

  • Ignore this parameter for Windows instances. It is null by default. Even if you enter this parameter, only the Password content is used.
  • The password logon method for Linux instances is set to forbidden upon initialization.
LaunchTemplateName string

The name of Launch Template.

Name string

The name of the data disk.

Deprecated:

Field 'name' has been deprecated from provider version 1.120.0. New field 'launch_template_name' instead.

NetworkInterfaces EcsLaunchTemplateNetworkInterfacesArgs

The list of network interfaces created with instance.

NetworkType string

Network type of the instance. Valid values: classic, vpc.

PasswordInherit bool

Whether to use the password preset by the mirror.

Period int

The subscription period of the instance. Unit: months. This parameter takes effect and is required only when InstanceChargeType is set to PrePaid. If the DedicatedHostId parameter is specified, the value of the Period parameter must be within the subscription period of the dedicated host.

  • When the PeriodUnit parameter is set to Week, the valid values of the Period parameter are 1, 2, 3, and 4.
  • When the PeriodUnit parameter is set to Month, the valid values of the Period parameter are 1, 2, 3, 4, 5, 6, 7, 8, 9, 12, 24, 36, 48, and 60.
PrivateIpAddress string

The private IP address of the instance.

RamRoleName string

The RAM role name of the instance. You can use the RAM API ListRoles to query instance RAM role names.

ResourceGroupId string

The ID of the resource group to which to assign the instance, Elastic Block Storage (EBS) device, and ENI.

SecurityEnhancementStrategy string

Whether or not to activate the security enhancement feature and install network security software free of charge. Valid values: Active, Deactive.

SecurityGroupId string

The security group ID must be one in the same VPC.

SecurityGroupIds []string

The ID of security group N to which to assign the instance.

SpotDuration string

The protection period of the preemptible instance. Unit: hours. Valid values: 0, 1, 2, 3, 4, 5, and 6. Default to: 1.

SpotPriceLimit float64

-(Optional) Sets the maximum hourly instance price. Supports up to three decimal places.

SpotStrategy string

The spot strategy for a Pay-As-You-Go instance. This parameter is valid and required only when InstanceChargeType is set to PostPaid. Valid values: NoSpot, SpotAsPriceGo, SpotWithPriceLimit.

SystemDisk EcsLaunchTemplateSystemDiskArgs

The System Disk.

SystemDiskCategory string

Deprecated:

Field 'system_disk_category' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

SystemDiskDescription string

Deprecated:

Field 'system_disk_description' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

SystemDiskName string

Deprecated:

Field 'system_disk_name' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

SystemDiskSize int

Deprecated:

Field 'system_disk_size' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

Tags map[string]interface{}

A mapping of tags to assign to instance, block storage, and elastic network.

  • Key: It can be up to 64 characters in length. It cannot begin with "aliyun", "acs:", "http://", or "https://". It cannot be a null string.
  • Value: It can be up to 128 characters in length. It cannot begin with "aliyun", "acs:", "http://", or "https://". It can be a null string.
TemplateResourceGroupId string

The template resource group id.

TemplateTags map[string]interface{}

A mapping of tags to assign to the launch template.

UserData string

The User Data.

Userdata string

Deprecated:

Field 'userdata' has been deprecated from provider version 1.120.0. New field 'user_data' instead.

VersionDescription string

The description of the launch template version. The description must be 2 to 256 characters in length and cannot start with http:// or https://.

VpcId string
VswitchId string

The VSwitch ID for ENI. The instance must be in the same zone of the same VPC network as the ENI, but they may belong to different VSwitches.

ZoneId string

The zone ID of the instance.

autoReleaseTime String

Instance auto release time. The time is presented using the ISO8601 standard and in UTC time. The format is YYYY-MM-DDTHH:MM:SSZ.

dataDisks List<EcsLaunchTemplateDataDiskArgs>

The list of data disks created with instance.

deploymentSetId String

The Deployment Set Id.

description String

The description of the data disk.

enableVmOsConfig Boolean

Whether to enable the instance operating system configuration.

hostName String

Instance host name.It cannot start or end with a period (.) or a hyphen (-) and it cannot have two or more consecutive periods (.) or hyphens (-).For Windows: The host name can be [2, 15] characters in length. It can contain A-Z, a-z, numbers, periods (.), and hyphens (-). It cannot only contain numbers. For other operating systems: The host name can be [2, 64] characters in length. It can be segments separated by periods (.). It can contain A-Z, a-z, numbers, and hyphens (-).

imageId String

The Image ID.

imageOwnerAlias String

Mirror source. Valid values: system, self, others, marketplace, "". Default to: "".

instanceChargeType String

Billing methods. Valid values: PostPaid, PrePaid.

instanceName String
instanceType String

Instance type. For more information, call resource_alicloud_instances to obtain the latest instance type list.

internetChargeType String

Internet bandwidth billing method. Valid values: PayByTraffic, PayByBandwidth.

internetMaxBandwidthIn Integer

The maximum inbound bandwidth from the Internet network, measured in Mbit/s. Value range: [1, 200].

internetMaxBandwidthOut Integer

Maximum outbound bandwidth from the Internet, its unit of measurement is Mbit/s. Value range: [0, 100].

ioOptimized String

Whether it is an I/O-optimized instance or not. Valid values: none, optimized.

keyPairName String

The name of the key pair.

  • Ignore this parameter for Windows instances. It is null by default. Even if you enter this parameter, only the Password content is used.
  • The password logon method for Linux instances is set to forbidden upon initialization.
launchTemplateName String

The name of Launch Template.

name String

The name of the data disk.

Deprecated:

Field 'name' has been deprecated from provider version 1.120.0. New field 'launch_template_name' instead.

networkInterfaces EcsLaunchTemplateNetworkInterfacesArgs

The list of network interfaces created with instance.

networkType String

Network type of the instance. Valid values: classic, vpc.

passwordInherit Boolean

Whether to use the password preset by the mirror.

period Integer

The subscription period of the instance. Unit: months. This parameter takes effect and is required only when InstanceChargeType is set to PrePaid. If the DedicatedHostId parameter is specified, the value of the Period parameter must be within the subscription period of the dedicated host.

  • When the PeriodUnit parameter is set to Week, the valid values of the Period parameter are 1, 2, 3, and 4.
  • When the PeriodUnit parameter is set to Month, the valid values of the Period parameter are 1, 2, 3, 4, 5, 6, 7, 8, 9, 12, 24, 36, 48, and 60.
privateIpAddress String

The private IP address of the instance.

ramRoleName String

The RAM role name of the instance. You can use the RAM API ListRoles to query instance RAM role names.

resourceGroupId String

The ID of the resource group to which to assign the instance, Elastic Block Storage (EBS) device, and ENI.

securityEnhancementStrategy String

Whether or not to activate the security enhancement feature and install network security software free of charge. Valid values: Active, Deactive.

securityGroupId String

The security group ID must be one in the same VPC.

securityGroupIds List<String>

The ID of security group N to which to assign the instance.

spotDuration String

The protection period of the preemptible instance. Unit: hours. Valid values: 0, 1, 2, 3, 4, 5, and 6. Default to: 1.

spotPriceLimit Double

-(Optional) Sets the maximum hourly instance price. Supports up to three decimal places.

spotStrategy String

The spot strategy for a Pay-As-You-Go instance. This parameter is valid and required only when InstanceChargeType is set to PostPaid. Valid values: NoSpot, SpotAsPriceGo, SpotWithPriceLimit.

systemDisk EcsLaunchTemplateSystemDiskArgs

The System Disk.

systemDiskCategory String

Deprecated:

Field 'system_disk_category' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

systemDiskDescription String

Deprecated:

Field 'system_disk_description' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

systemDiskName String

Deprecated:

Field 'system_disk_name' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

systemDiskSize Integer

Deprecated:

Field 'system_disk_size' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

tags Map<String,Object>

A mapping of tags to assign to instance, block storage, and elastic network.

  • Key: It can be up to 64 characters in length. It cannot begin with "aliyun", "acs:", "http://", or "https://". It cannot be a null string.
  • Value: It can be up to 128 characters in length. It cannot begin with "aliyun", "acs:", "http://", or "https://". It can be a null string.
templateResourceGroupId String

The template resource group id.

templateTags Map<String,Object>

A mapping of tags to assign to the launch template.

userData String

The User Data.

userdata String

Deprecated:

Field 'userdata' has been deprecated from provider version 1.120.0. New field 'user_data' instead.

versionDescription String

The description of the launch template version. The description must be 2 to 256 characters in length and cannot start with http:// or https://.

vpcId String
vswitchId String

The VSwitch ID for ENI. The instance must be in the same zone of the same VPC network as the ENI, but they may belong to different VSwitches.

zoneId String

The zone ID of the instance.

autoReleaseTime string

Instance auto release time. The time is presented using the ISO8601 standard and in UTC time. The format is YYYY-MM-DDTHH:MM:SSZ.

dataDisks EcsLaunchTemplateDataDiskArgs[]

The list of data disks created with instance.

deploymentSetId string

The Deployment Set Id.

description string

The description of the data disk.

enableVmOsConfig boolean

Whether to enable the instance operating system configuration.

hostName string

Instance host name.It cannot start or end with a period (.) or a hyphen (-) and it cannot have two or more consecutive periods (.) or hyphens (-).For Windows: The host name can be [2, 15] characters in length. It can contain A-Z, a-z, numbers, periods (.), and hyphens (-). It cannot only contain numbers. For other operating systems: The host name can be [2, 64] characters in length. It can be segments separated by periods (.). It can contain A-Z, a-z, numbers, and hyphens (-).

imageId string

The Image ID.

imageOwnerAlias string

Mirror source. Valid values: system, self, others, marketplace, "". Default to: "".

instanceChargeType string

Billing methods. Valid values: PostPaid, PrePaid.

instanceName string
instanceType string

Instance type. For more information, call resource_alicloud_instances to obtain the latest instance type list.

internetChargeType string

Internet bandwidth billing method. Valid values: PayByTraffic, PayByBandwidth.

internetMaxBandwidthIn number

The maximum inbound bandwidth from the Internet network, measured in Mbit/s. Value range: [1, 200].

internetMaxBandwidthOut number

Maximum outbound bandwidth from the Internet, its unit of measurement is Mbit/s. Value range: [0, 100].

ioOptimized string

Whether it is an I/O-optimized instance or not. Valid values: none, optimized.

keyPairName string

The name of the key pair.

  • Ignore this parameter for Windows instances. It is null by default. Even if you enter this parameter, only the Password content is used.
  • The password logon method for Linux instances is set to forbidden upon initialization.
launchTemplateName string

The name of Launch Template.

name string

The name of the data disk.

Deprecated:

Field 'name' has been deprecated from provider version 1.120.0. New field 'launch_template_name' instead.

networkInterfaces EcsLaunchTemplateNetworkInterfacesArgs

The list of network interfaces created with instance.

networkType string

Network type of the instance. Valid values: classic, vpc.

passwordInherit boolean

Whether to use the password preset by the mirror.

period number

The subscription period of the instance. Unit: months. This parameter takes effect and is required only when InstanceChargeType is set to PrePaid. If the DedicatedHostId parameter is specified, the value of the Period parameter must be within the subscription period of the dedicated host.

  • When the PeriodUnit parameter is set to Week, the valid values of the Period parameter are 1, 2, 3, and 4.
  • When the PeriodUnit parameter is set to Month, the valid values of the Period parameter are 1, 2, 3, 4, 5, 6, 7, 8, 9, 12, 24, 36, 48, and 60.
privateIpAddress string

The private IP address of the instance.

ramRoleName string

The RAM role name of the instance. You can use the RAM API ListRoles to query instance RAM role names.

resourceGroupId string

The ID of the resource group to which to assign the instance, Elastic Block Storage (EBS) device, and ENI.

securityEnhancementStrategy string

Whether or not to activate the security enhancement feature and install network security software free of charge. Valid values: Active, Deactive.

securityGroupId string

The security group ID must be one in the same VPC.

securityGroupIds string[]

The ID of security group N to which to assign the instance.

spotDuration string

The protection period of the preemptible instance. Unit: hours. Valid values: 0, 1, 2, 3, 4, 5, and 6. Default to: 1.

spotPriceLimit number

-(Optional) Sets the maximum hourly instance price. Supports up to three decimal places.

spotStrategy string

The spot strategy for a Pay-As-You-Go instance. This parameter is valid and required only when InstanceChargeType is set to PostPaid. Valid values: NoSpot, SpotAsPriceGo, SpotWithPriceLimit.

systemDisk EcsLaunchTemplateSystemDiskArgs

The System Disk.

systemDiskCategory string

Deprecated:

Field 'system_disk_category' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

systemDiskDescription string

Deprecated:

Field 'system_disk_description' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

systemDiskName string

Deprecated:

Field 'system_disk_name' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

systemDiskSize number

Deprecated:

Field 'system_disk_size' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

tags {[key: string]: any}

A mapping of tags to assign to instance, block storage, and elastic network.

  • Key: It can be up to 64 characters in length. It cannot begin with "aliyun", "acs:", "http://", or "https://". It cannot be a null string.
  • Value: It can be up to 128 characters in length. It cannot begin with "aliyun", "acs:", "http://", or "https://". It can be a null string.
templateResourceGroupId string

The template resource group id.

templateTags {[key: string]: any}

A mapping of tags to assign to the launch template.

userData string

The User Data.

userdata string

Deprecated:

Field 'userdata' has been deprecated from provider version 1.120.0. New field 'user_data' instead.

versionDescription string

The description of the launch template version. The description must be 2 to 256 characters in length and cannot start with http:// or https://.

vpcId string
vswitchId string

The VSwitch ID for ENI. The instance must be in the same zone of the same VPC network as the ENI, but they may belong to different VSwitches.

zoneId string

The zone ID of the instance.

auto_release_time str

Instance auto release time. The time is presented using the ISO8601 standard and in UTC time. The format is YYYY-MM-DDTHH:MM:SSZ.

data_disks Sequence[EcsLaunchTemplateDataDiskArgs]

The list of data disks created with instance.

deployment_set_id str

The Deployment Set Id.

description str

The description of the data disk.

enable_vm_os_config bool

Whether to enable the instance operating system configuration.

host_name str

Instance host name.It cannot start or end with a period (.) or a hyphen (-) and it cannot have two or more consecutive periods (.) or hyphens (-).For Windows: The host name can be [2, 15] characters in length. It can contain A-Z, a-z, numbers, periods (.), and hyphens (-). It cannot only contain numbers. For other operating systems: The host name can be [2, 64] characters in length. It can be segments separated by periods (.). It can contain A-Z, a-z, numbers, and hyphens (-).

image_id str

The Image ID.

image_owner_alias str

Mirror source. Valid values: system, self, others, marketplace, "". Default to: "".

instance_charge_type str

Billing methods. Valid values: PostPaid, PrePaid.

instance_name str
instance_type str

Instance type. For more information, call resource_alicloud_instances to obtain the latest instance type list.

internet_charge_type str

Internet bandwidth billing method. Valid values: PayByTraffic, PayByBandwidth.

internet_max_bandwidth_in int

The maximum inbound bandwidth from the Internet network, measured in Mbit/s. Value range: [1, 200].

internet_max_bandwidth_out int

Maximum outbound bandwidth from the Internet, its unit of measurement is Mbit/s. Value range: [0, 100].

io_optimized str

Whether it is an I/O-optimized instance or not. Valid values: none, optimized.

key_pair_name str

The name of the key pair.

  • Ignore this parameter for Windows instances. It is null by default. Even if you enter this parameter, only the Password content is used.
  • The password logon method for Linux instances is set to forbidden upon initialization.
launch_template_name str

The name of Launch Template.

name str

The name of the data disk.

Deprecated:

Field 'name' has been deprecated from provider version 1.120.0. New field 'launch_template_name' instead.

network_interfaces EcsLaunchTemplateNetworkInterfacesArgs

The list of network interfaces created with instance.

network_type str

Network type of the instance. Valid values: classic, vpc.

password_inherit bool

Whether to use the password preset by the mirror.

period int

The subscription period of the instance. Unit: months. This parameter takes effect and is required only when InstanceChargeType is set to PrePaid. If the DedicatedHostId parameter is specified, the value of the Period parameter must be within the subscription period of the dedicated host.

  • When the PeriodUnit parameter is set to Week, the valid values of the Period parameter are 1, 2, 3, and 4.
  • When the PeriodUnit parameter is set to Month, the valid values of the Period parameter are 1, 2, 3, 4, 5, 6, 7, 8, 9, 12, 24, 36, 48, and 60.
private_ip_address str

The private IP address of the instance.

ram_role_name str

The RAM role name of the instance. You can use the RAM API ListRoles to query instance RAM role names.

resource_group_id str

The ID of the resource group to which to assign the instance, Elastic Block Storage (EBS) device, and ENI.

security_enhancement_strategy str

Whether or not to activate the security enhancement feature and install network security software free of charge. Valid values: Active, Deactive.

security_group_id str

The security group ID must be one in the same VPC.

security_group_ids Sequence[str]

The ID of security group N to which to assign the instance.

spot_duration str

The protection period of the preemptible instance. Unit: hours. Valid values: 0, 1, 2, 3, 4, 5, and 6. Default to: 1.

spot_price_limit float

-(Optional) Sets the maximum hourly instance price. Supports up to three decimal places.

spot_strategy str

The spot strategy for a Pay-As-You-Go instance. This parameter is valid and required only when InstanceChargeType is set to PostPaid. Valid values: NoSpot, SpotAsPriceGo, SpotWithPriceLimit.

system_disk EcsLaunchTemplateSystemDiskArgs

The System Disk.

system_disk_category str

Deprecated:

Field 'system_disk_category' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

system_disk_description str

Deprecated:

Field 'system_disk_description' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

system_disk_name str

Deprecated:

Field 'system_disk_name' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

system_disk_size int

Deprecated:

Field 'system_disk_size' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

tags Mapping[str, Any]

A mapping of tags to assign to instance, block storage, and elastic network.

  • Key: It can be up to 64 characters in length. It cannot begin with "aliyun", "acs:", "http://", or "https://". It cannot be a null string.
  • Value: It can be up to 128 characters in length. It cannot begin with "aliyun", "acs:", "http://", or "https://". It can be a null string.
template_resource_group_id str

The template resource group id.

template_tags Mapping[str, Any]

A mapping of tags to assign to the launch template.

user_data str

The User Data.

userdata str

Deprecated:

Field 'userdata' has been deprecated from provider version 1.120.0. New field 'user_data' instead.

version_description str

The description of the launch template version. The description must be 2 to 256 characters in length and cannot start with http:// or https://.

vpc_id str
vswitch_id str

The VSwitch ID for ENI. The instance must be in the same zone of the same VPC network as the ENI, but they may belong to different VSwitches.

zone_id str

The zone ID of the instance.

autoReleaseTime String

Instance auto release time. The time is presented using the ISO8601 standard and in UTC time. The format is YYYY-MM-DDTHH:MM:SSZ.

dataDisks List<Property Map>

The list of data disks created with instance.

deploymentSetId String

The Deployment Set Id.

description String

The description of the data disk.

enableVmOsConfig Boolean

Whether to enable the instance operating system configuration.

hostName String

Instance host name.It cannot start or end with a period (.) or a hyphen (-) and it cannot have two or more consecutive periods (.) or hyphens (-).For Windows: The host name can be [2, 15] characters in length. It can contain A-Z, a-z, numbers, periods (.), and hyphens (-). It cannot only contain numbers. For other operating systems: The host name can be [2, 64] characters in length. It can be segments separated by periods (.). It can contain A-Z, a-z, numbers, and hyphens (-).

imageId String

The Image ID.

imageOwnerAlias String

Mirror source. Valid values: system, self, others, marketplace, "". Default to: "".

instanceChargeType String

Billing methods. Valid values: PostPaid, PrePaid.

instanceName String
instanceType String

Instance type. For more information, call resource_alicloud_instances to obtain the latest instance type list.

internetChargeType String

Internet bandwidth billing method. Valid values: PayByTraffic, PayByBandwidth.

internetMaxBandwidthIn Number

The maximum inbound bandwidth from the Internet network, measured in Mbit/s. Value range: [1, 200].

internetMaxBandwidthOut Number

Maximum outbound bandwidth from the Internet, its unit of measurement is Mbit/s. Value range: [0, 100].

ioOptimized String

Whether it is an I/O-optimized instance or not. Valid values: none, optimized.

keyPairName String

The name of the key pair.

  • Ignore this parameter for Windows instances. It is null by default. Even if you enter this parameter, only the Password content is used.
  • The password logon method for Linux instances is set to forbidden upon initialization.
launchTemplateName String

The name of Launch Template.

name String

The name of the data disk.

Deprecated:

Field 'name' has been deprecated from provider version 1.120.0. New field 'launch_template_name' instead.

networkInterfaces Property Map

The list of network interfaces created with instance.

networkType String

Network type of the instance. Valid values: classic, vpc.

passwordInherit Boolean

Whether to use the password preset by the mirror.

period Number

The subscription period of the instance. Unit: months. This parameter takes effect and is required only when InstanceChargeType is set to PrePaid. If the DedicatedHostId parameter is specified, the value of the Period parameter must be within the subscription period of the dedicated host.

  • When the PeriodUnit parameter is set to Week, the valid values of the Period parameter are 1, 2, 3, and 4.
  • When the PeriodUnit parameter is set to Month, the valid values of the Period parameter are 1, 2, 3, 4, 5, 6, 7, 8, 9, 12, 24, 36, 48, and 60.
privateIpAddress String

The private IP address of the instance.

ramRoleName String

The RAM role name of the instance. You can use the RAM API ListRoles to query instance RAM role names.

resourceGroupId String

The ID of the resource group to which to assign the instance, Elastic Block Storage (EBS) device, and ENI.

securityEnhancementStrategy String

Whether or not to activate the security enhancement feature and install network security software free of charge. Valid values: Active, Deactive.

securityGroupId String

The security group ID must be one in the same VPC.

securityGroupIds List<String>

The ID of security group N to which to assign the instance.

spotDuration String

The protection period of the preemptible instance. Unit: hours. Valid values: 0, 1, 2, 3, 4, 5, and 6. Default to: 1.

spotPriceLimit Number

-(Optional) Sets the maximum hourly instance price. Supports up to three decimal places.

spotStrategy String

The spot strategy for a Pay-As-You-Go instance. This parameter is valid and required only when InstanceChargeType is set to PostPaid. Valid values: NoSpot, SpotAsPriceGo, SpotWithPriceLimit.

systemDisk Property Map

The System Disk.

systemDiskCategory String

Deprecated:

Field 'system_disk_category' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

systemDiskDescription String

Deprecated:

Field 'system_disk_description' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

systemDiskName String

Deprecated:

Field 'system_disk_name' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

systemDiskSize Number

Deprecated:

Field 'system_disk_size' has been deprecated from provider version 1.120.0. New field 'system_disk' instead.

tags Map<Any>

A mapping of tags to assign to instance, block storage, and elastic network.

  • Key: It can be up to 64 characters in length. It cannot begin with "aliyun", "acs:", "http://", or "https://". It cannot be a null string.
  • Value: It can be up to 128 characters in length. It cannot begin with "aliyun", "acs:", "http://", or "https://". It can be a null string.
templateResourceGroupId String

The template resource group id.

templateTags Map<Any>

A mapping of tags to assign to the launch template.

userData String

The User Data.

userdata String

Deprecated:

Field 'userdata' has been deprecated from provider version 1.120.0. New field 'user_data' instead.

versionDescription String

The description of the launch template version. The description must be 2 to 256 characters in length and cannot start with http:// or https://.

vpcId String
vswitchId String

The VSwitch ID for ENI. The instance must be in the same zone of the same VPC network as the ENI, but they may belong to different VSwitches.

zoneId String

The zone ID of the instance.

Supporting Types

EcsLaunchTemplateDataDisk

Category string

The category of the disk.

DeleteWithInstance bool

Indicates whether the data disk is released with the instance.

Description string

The description of the data disk.

Encrypted bool

Encrypted the data in this disk.

Name string

The name of the data disk.

PerformanceLevel string

The performance level of the ESSD used as the data disk.

Size int

The size of the data disk.

SnapshotId string

The snapshot ID used to initialize the data disk. If the size specified by snapshot is greater that the size of the disk, use the size specified by snapshot as the size of the data disk.

Category string

The category of the disk.

DeleteWithInstance bool

Indicates whether the data disk is released with the instance.

Description string

The description of the data disk.

Encrypted bool

Encrypted the data in this disk.

Name string

The name of the data disk.

PerformanceLevel string

The performance level of the ESSD used as the data disk.

Size int

The size of the data disk.

SnapshotId string

The snapshot ID used to initialize the data disk. If the size specified by snapshot is greater that the size of the disk, use the size specified by snapshot as the size of the data disk.

category String

The category of the disk.

deleteWithInstance Boolean

Indicates whether the data disk is released with the instance.

description String

The description of the data disk.

encrypted Boolean

Encrypted the data in this disk.

name String

The name of the data disk.

performanceLevel String

The performance level of the ESSD used as the data disk.

size Integer

The size of the data disk.

snapshotId String

The snapshot ID used to initialize the data disk. If the size specified by snapshot is greater that the size of the disk, use the size specified by snapshot as the size of the data disk.

category string

The category of the disk.

deleteWithInstance boolean

Indicates whether the data disk is released with the instance.

description string

The description of the data disk.

encrypted boolean

Encrypted the data in this disk.

name string

The name of the data disk.

performanceLevel string

The performance level of the ESSD used as the data disk.

size number

The size of the data disk.

snapshotId string

The snapshot ID used to initialize the data disk. If the size specified by snapshot is greater that the size of the disk, use the size specified by snapshot as the size of the data disk.

category str

The category of the disk.

delete_with_instance bool

Indicates whether the data disk is released with the instance.

description str

The description of the data disk.

encrypted bool

Encrypted the data in this disk.

name str

The name of the data disk.

performance_level str

The performance level of the ESSD used as the data disk.

size int

The size of the data disk.

snapshot_id str

The snapshot ID used to initialize the data disk. If the size specified by snapshot is greater that the size of the disk, use the size specified by snapshot as the size of the data disk.

category String

The category of the disk.

deleteWithInstance Boolean

Indicates whether the data disk is released with the instance.

description String

The description of the data disk.

encrypted Boolean

Encrypted the data in this disk.

name String

The name of the data disk.

performanceLevel String

The performance level of the ESSD used as the data disk.

size Number

The size of the data disk.

snapshotId String

The snapshot ID used to initialize the data disk. If the size specified by snapshot is greater that the size of the disk, use the size specified by snapshot as the size of the data disk.

EcsLaunchTemplateNetworkInterfaces

Description string

The description of the data disk.

Name string

The name of the data disk.

PrimaryIp string

The primary private IP address of the ENI.

SecurityGroupId string

The security group ID must be one in the same VPC.

VswitchId string

The VSwitch ID for ENI. The instance must be in the same zone of the same VPC network as the ENI, but they may belong to different VSwitches.

Description string

The description of the data disk.

Name string

The name of the data disk.

PrimaryIp string

The primary private IP address of the ENI.

SecurityGroupId string

The security group ID must be one in the same VPC.

VswitchId string

The VSwitch ID for ENI. The instance must be in the same zone of the same VPC network as the ENI, but they may belong to different VSwitches.

description String

The description of the data disk.

name String

The name of the data disk.

primaryIp String

The primary private IP address of the ENI.

securityGroupId String

The security group ID must be one in the same VPC.

vswitchId String

The VSwitch ID for ENI. The instance must be in the same zone of the same VPC network as the ENI, but they may belong to different VSwitches.

description string

The description of the data disk.

name string

The name of the data disk.

primaryIp string

The primary private IP address of the ENI.

securityGroupId string

The security group ID must be one in the same VPC.

vswitchId string

The VSwitch ID for ENI. The instance must be in the same zone of the same VPC network as the ENI, but they may belong to different VSwitches.

description str

The description of the data disk.

name str

The name of the data disk.

primary_ip str

The primary private IP address of the ENI.

security_group_id str

The security group ID must be one in the same VPC.

vswitch_id str

The VSwitch ID for ENI. The instance must be in the same zone of the same VPC network as the ENI, but they may belong to different VSwitches.

description String

The description of the data disk.

name String

The name of the data disk.

primaryIp String

The primary private IP address of the ENI.

securityGroupId String

The security group ID must be one in the same VPC.

vswitchId String

The VSwitch ID for ENI. The instance must be in the same zone of the same VPC network as the ENI, but they may belong to different VSwitches.

EcsLaunchTemplateSystemDisk

Category string

The category of the disk.

DeleteWithInstance bool

Indicates whether the data disk is released with the instance.

Description string

The description of the data disk.

Iops string

The Iops.

Name string

The name of the data disk.

PerformanceLevel string

The performance level of the ESSD used as the data disk.

Size int

The size of the data disk.

Category string

The category of the disk.

DeleteWithInstance bool

Indicates whether the data disk is released with the instance.

Description string

The description of the data disk.

Iops string

The Iops.

Name string

The name of the data disk.

PerformanceLevel string

The performance level of the ESSD used as the data disk.

Size int

The size of the data disk.

category String

The category of the disk.

deleteWithInstance Boolean

Indicates whether the data disk is released with the instance.

description String

The description of the data disk.

iops String

The Iops.

name String

The name of the data disk.

performanceLevel String

The performance level of the ESSD used as the data disk.

size Integer

The size of the data disk.

category string

The category of the disk.

deleteWithInstance boolean

Indicates whether the data disk is released with the instance.

description string

The description of the data disk.

iops string

The Iops.

name string

The name of the data disk.

performanceLevel string

The performance level of the ESSD used as the data disk.

size number

The size of the data disk.

category str

The category of the disk.

delete_with_instance bool

Indicates whether the data disk is released with the instance.

description str

The description of the data disk.

iops str

The Iops.

name str

The name of the data disk.

performance_level str

The performance level of the ESSD used as the data disk.

size int

The size of the data disk.

category String

The category of the disk.

deleteWithInstance Boolean

Indicates whether the data disk is released with the instance.

description String

The description of the data disk.

iops String

The Iops.

name String

The name of the data disk.

performanceLevel String

The performance level of the ESSD used as the data disk.

size Number

The size of the data disk.

Import

ECS Launch Template can be imported using the id, e.g.

 $ pulumi import alicloud:ecs/ecsLaunchTemplate:EcsLaunchTemplate example <id>

Package Details

Repository
https://github.com/pulumi/pulumi-alicloud
License
Apache-2.0
Notes

This Pulumi package is based on the alicloud Terraform Provider.