Skip to content

LaunchTemplate

  • Implements: @alicloud/ros-cdk-ecs.datasource.ILaunchTemplate

This class encapsulates and extends the ROS resource type DATASOURCE::ECS::LaunchTemplate.

Initializers

import { datasource } from '@alicloud/ros-cdk-ecs'
new datasource.LaunchTemplate(scope: Construct, id: string, props: LaunchTemplateProps, enableResourcePropertyConstraint?: boolean)
Name Type Description
scope @alicloud/ros-cdk-core.Construct No description.
id string No description.
props LaunchTemplateProps No description.
enableResourcePropertyConstraint boolean No description.

scopeRequired

  • Type: @alicloud/ros-cdk-core.Construct

idRequired

  • Type: string

propsRequired


enableResourcePropertyConstraintOptional

  • Type: boolean

Methods

Name Description
toString Returns a string representation of this construct.
synthesize Allows this construct to emit artifacts into the cloud assembly during synthesis.
addCondition No description.
addCount No description.
addDependency No description.
addResourceDesc No description.
applyRemovalPolicy No description.
fetchCondition No description.
fetchDependency No description.
fetchResourceDesc No description.
getAtt No description.
setMetadata No description.

toString

public toString(): string

Returns a string representation of this construct.

synthesize

public synthesize(session: ISynthesisSession): void

Allows this construct to emit artifacts into the cloud assembly during synthesis.

This method is usually implemented by framework-level constructs such as Stack and Asset as they participate in synthesizing the cloud assembly.

sessionRequired

  • Type: @alicloud/ros-cdk-core.ISynthesisSession

The synthesis session.


addCondition

public addCondition(condition: RosCondition): void

conditionRequired

  • Type: @alicloud/ros-cdk-core.RosCondition

addCount

public addCount(count: number | IResolvable): void

countRequired

  • Type: number | @alicloud/ros-cdk-core.IResolvable

addDependency

public addDependency(resource: Resource): void

resourceRequired

  • Type: @alicloud/ros-cdk-core.Resource

addResourceDesc

public addResourceDesc(desc: string): void

descRequired

  • Type: string

applyRemovalPolicy

public applyRemovalPolicy(policy: RemovalPolicy): void

policyRequired

  • Type: @alicloud/ros-cdk-core.RemovalPolicy

fetchCondition

public fetchCondition(): RosCondition

fetchDependency

public fetchDependency(): string[]

fetchResourceDesc

public fetchResourceDesc(): string

getAtt

public getAtt(name: string): IResolvable

nameRequired

  • Type: string

setMetadata

public setMetadata(key: string, value: any): void

keyRequired

  • Type: string

valueRequired

  • Type: any

Static Functions

Name Description
isConstruct Return whether the given object is a Construct.

isConstruct

import { datasource } from '@alicloud/ros-cdk-ecs'
datasource.LaunchTemplate.isConstruct(x: any)

Return whether the given object is a Construct.

xRequired

  • Type: any

Properties

Name Type Description
node @alicloud/ros-cdk-core.ConstructNode The construct tree node associated with this construct.
env @alicloud/ros-cdk-core.IResourceEnvironment The environment this resource belongs to.
ref string No description.
stack @alicloud/ros-cdk-core.Stack The stack in which this resource is defined.
resource @alicloud/ros-cdk-core.RosResource No description.
attrAutoReleaseTime string | @alicloud/ros-cdk-core.IResolvable Attribute AutoReleaseTime: Automatic release time (UTC).
attrCreatedBy string | @alicloud/ros-cdk-core.IResolvable Attribute CreatedBy: The creator of the launch template.
attrCreateTime string | @alicloud/ros-cdk-core.IResolvable Attribute CreateTime: The time when the instance launch template was created.
attrDataDisk string | @alicloud/ros-cdk-core.IResolvable Attribute DataDisk: Data disk information list.
attrDefaultVersionNumber string | @alicloud/ros-cdk-core.IResolvable Attribute DefaultVersionNumber: The default version number of the template.
attrDeletionProtection string | @alicloud/ros-cdk-core.IResolvable Attribute DeletionProtection: Instance deletion protection attribute.
attrDeploymentSetId string | @alicloud/ros-cdk-core.IResolvable Attribute DeploymentSetId: The ID of the deployment set.
attrDescription string | @alicloud/ros-cdk-core.IResolvable Attribute Description: Instance description.
attrHostName string | @alicloud/ros-cdk-core.IResolvable Attribute HostName: The hostname of the instance.
attrImageId string | @alicloud/ros-cdk-core.IResolvable Attribute ImageId: The ID of the image.
attrImageOwnerAlias string | @alicloud/ros-cdk-core.IResolvable Attribute ImageOwnerAlias: The source of the image.
attrInstanceChargeType string | @alicloud/ros-cdk-core.IResolvable Attribute InstanceChargeType: The billing method of the instance.
attrInstanceName string | @alicloud/ros-cdk-core.IResolvable Attribute InstanceName: The name of the instance.
attrInstanceType string | @alicloud/ros-cdk-core.IResolvable Attribute InstanceType: The instance type.
attrInternetChargeType string | @alicloud/ros-cdk-core.IResolvable Attribute InternetChargeType: Network billing method.
attrInternetMaxBandwidthIn string | @alicloud/ros-cdk-core.IResolvable Attribute InternetMaxBandwidthIn: The maximum public inbound bandwidth, in Mbit/s.
attrInternetMaxBandwidthOut string | @alicloud/ros-cdk-core.IResolvable Attribute InternetMaxBandwidthOut: The maximum outbound bandwidth of the public network.
attrIoOptimized string | @alicloud/ros-cdk-core.IResolvable Attribute IoOptimized: Whether to optimize the instance for I/O.
attrIpv6AddressCount string | @alicloud/ros-cdk-core.IResolvable Attribute Ipv6AddressCount: Specify the number of randomly generated IPv6 addresses for the primary network card.
attrKeyPairName string | @alicloud/ros-cdk-core.IResolvable Attribute KeyPairName: The name of the key pair.
attrLatestVersionNumber string | @alicloud/ros-cdk-core.IResolvable Attribute LatestVersionNumber: The latest version number of the template.
attrLaunchTemplateId string | @alicloud/ros-cdk-core.IResolvable Attribute LaunchTemplateId: The ID of the launch template.
attrLaunchTemplateName string | @alicloud/ros-cdk-core.IResolvable Attribute LaunchTemplateName: The name of the launch template.
attrModifiedTime string | @alicloud/ros-cdk-core.IResolvable Attribute ModifiedTime: The time when the launch template was modified.
attrNetworkInterface string | @alicloud/ros-cdk-core.IResolvable Attribute NetworkInterface: The elastic network interfaces (ENIs).
attrNetworkType string | @alicloud/ros-cdk-core.IResolvable Attribute NetworkType: The network type of the instance.
attrPasswordInherit string | @alicloud/ros-cdk-core.IResolvable Attribute PasswordInherit: Whether to use the password preset by the image.
attrPeriod string | @alicloud/ros-cdk-core.IResolvable Attribute Period: The duration of the purchase of resources, in months.
attrPrivateIpAddress string | @alicloud/ros-cdk-core.IResolvable Attribute PrivateIpAddress: The private IP address of the instance.
attrRamRoleName string | @alicloud/ros-cdk-core.IResolvable Attribute RamRoleName: The instance RAM role name.
attrResourceGroupId string | @alicloud/ros-cdk-core.IResolvable Attribute ResourceGroupId: The ID of the resource group to which the instance, Elastic Block Storage (EBS) device, and ENI belong.
attrSecurityEnhancementStrategy string | @alicloud/ros-cdk-core.IResolvable Attribute SecurityEnhancementStrategy: Whether to turn on security reinforcement for the operating system.
attrSecurityGroupIds string | @alicloud/ros-cdk-core.IResolvable Attribute SecurityGroupIds: The IDs of one or more security groups to which you want to add the instance.
attrSpotPriceLimit string | @alicloud/ros-cdk-core.IResolvable Attribute SpotPriceLimit: Set the maximum price per hour for the instance.
attrSpotStrategy string | @alicloud/ros-cdk-core.IResolvable Attribute SpotStrategy: The preemption policy for a pay-as-you-go instance.
attrSystemDisk string | @alicloud/ros-cdk-core.IResolvable Attribute SystemDisk: System disk configuration.
attrTags string | @alicloud/ros-cdk-core.IResolvable Attribute Tags: The tags of the launch template.
attrTemplateResourceGroupId string | @alicloud/ros-cdk-core.IResolvable Attribute TemplateResourceGroupId: Q.
attrTemplateTag string | @alicloud/ros-cdk-core.IResolvable Attribute TemplateTag: The tags of the launch template.
attrUserData string | @alicloud/ros-cdk-core.IResolvable Attribute UserData: The user-defined data of the instance must be encoded in Base64.
attrVersionDescription string | @alicloud/ros-cdk-core.IResolvable Attribute VersionDescription: Instance launch template version description.
attrVpcId string | @alicloud/ros-cdk-core.IResolvable Attribute VpcId: VPC Id.
attrVSwitchId string | @alicloud/ros-cdk-core.IResolvable Attribute VSwitchId: The ID of the vSwitch.
attrZoneId string | @alicloud/ros-cdk-core.IResolvable Attribute ZoneId: The ID of the zone to which the instance belongs.
props LaunchTemplateProps No description.

nodeRequired

public readonly node: ConstructNode;
  • Type: @alicloud/ros-cdk-core.ConstructNode

The construct tree node associated with this construct.


envRequired

public readonly env: IResourceEnvironment;
  • Type: @alicloud/ros-cdk-core.IResourceEnvironment

The environment this resource belongs to.

For resources that are created and managed by the CDK (generally, those created by creating new class instances like Role, Bucket, etc.), this is always the same as the environment of the stack they belong to; however, for imported resources (those obtained from static methods like fromRoleArn, fromBucketName, etc.), that might be different than the stack they were imported into.


refRequired

public readonly ref: string;
  • Type: string

stackRequired

public readonly stack: Stack;
  • Type: @alicloud/ros-cdk-core.Stack

The stack in which this resource is defined.


resourceOptional

public readonly resource: RosResource;
  • Type: @alicloud/ros-cdk-core.RosResource

attrAutoReleaseTimeRequired

public readonly attrAutoReleaseTime: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute AutoReleaseTime: Automatic release time (UTC).

The format is: yyyy-MM-ddTHH:mm:ssZ.


attrCreatedByRequired

public readonly attrCreatedBy: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute CreatedBy: The creator of the launch template.


attrCreateTimeRequired

public readonly attrCreateTime: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute CreateTime: The time when the instance launch template was created.


attrDataDiskRequired

public readonly attrDataDisk: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute DataDisk: Data disk information list.


attrDefaultVersionNumberRequired

public readonly attrDefaultVersionNumber: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute DefaultVersionNumber: The default version number of the template.


attrDeletionProtectionRequired

public readonly attrDeletionProtection: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute DeletionProtection: Instance deletion protection attribute.


attrDeploymentSetIdRequired

public readonly attrDeploymentSetId: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute DeploymentSetId: The ID of the deployment set.


attrDescriptionRequired

public readonly attrDescription: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute Description: Instance description.

2 to 256 English or Chinese characters in length and cannot start with' http:// 'or' https.


attrHostNameRequired

public readonly attrHostName: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute HostName: The hostname of the instance.


attrImageIdRequired

public readonly attrImageId: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute ImageId: The ID of the image.


attrImageOwnerAliasRequired

public readonly attrImageOwnerAlias: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute ImageOwnerAlias: The source of the image.


attrInstanceChargeTypeRequired

public readonly attrInstanceChargeType: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute InstanceChargeType: The billing method of the instance.


attrInstanceNameRequired

public readonly attrInstanceName: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute InstanceName: The name of the instance.

The length is 2~128 English or Chinese characters. It must start with a large or small letter or Chinese, and cannot start with' http:// 'or' https. It can contain numbers, colons (:), underscores (_), or dashes (-).


attrInstanceTypeRequired

public readonly attrInstanceType: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute InstanceType: The instance type.


attrInternetChargeTypeRequired

public readonly attrInternetChargeType: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute InternetChargeType: Network billing method.


attrInternetMaxBandwidthInRequired

public readonly attrInternetMaxBandwidthIn: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute InternetMaxBandwidthIn: The maximum public inbound bandwidth, in Mbit/s.


attrInternetMaxBandwidthOutRequired

public readonly attrInternetMaxBandwidthOut: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute InternetMaxBandwidthOut: The maximum outbound bandwidth of the public network.

The unit is Mbit/s. The value range is 0~100.


attrIoOptimizedRequired

public readonly attrIoOptimized: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute IoOptimized: Whether to optimize the instance for I/O.


attrIpv6AddressCountRequired

public readonly attrIpv6AddressCount: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute Ipv6AddressCount: Specify the number of randomly generated IPv6 addresses for the primary network card.

The value range is 1 to 10.


attrKeyPairNameRequired

public readonly attrKeyPairName: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute KeyPairName: The name of the key pair.


attrLatestVersionNumberRequired

public readonly attrLatestVersionNumber: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute LatestVersionNumber: The latest version number of the template.


attrLaunchTemplateIdRequired

public readonly attrLaunchTemplateId: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute LaunchTemplateId: The ID of the launch template.


attrLaunchTemplateNameRequired

public readonly attrLaunchTemplateName: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute LaunchTemplateName: The name of the launch template.


attrModifiedTimeRequired

public readonly attrModifiedTime: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute ModifiedTime: The time when the launch template was modified.


attrNetworkInterfaceRequired

public readonly attrNetworkInterface: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute NetworkInterface: The elastic network interfaces (ENIs).


attrNetworkTypeRequired

public readonly attrNetworkType: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute NetworkType: The network type of the instance.


attrPasswordInheritRequired

public readonly attrPasswordInherit: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute PasswordInherit: Whether to use the password preset by the image.


attrPeriodRequired

public readonly attrPeriod: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute Period: The duration of the purchase of resources, in months.

When creating an instance, the parameter 'InstanceChargeType' takes effect and is required only when the value of the parameter 'PrePaid' is 'PrePaid. Value range: 1, 2, 3, 4, 5, 6, 7, 8, 9, 12, 24, 36, 48, 60.


attrPrivateIpAddressRequired

public readonly attrPrivateIpAddress: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute PrivateIpAddress: The private IP address of the instance.


attrRamRoleNameRequired

public readonly attrRamRoleName: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute RamRoleName: The instance RAM role name.


attrResourceGroupIdRequired

public readonly attrResourceGroupId: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

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


attrSecurityEnhancementStrategyRequired

public readonly attrSecurityEnhancementStrategy: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute SecurityEnhancementStrategy: Whether to turn on security reinforcement for the operating system.


attrSecurityGroupIdsRequired

public readonly attrSecurityGroupIds: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute SecurityGroupIds: The IDs of one or more security groups to which you want to add the instance.


attrSpotPriceLimitRequired

public readonly attrSpotPriceLimit: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute SpotPriceLimit: Set the maximum price per hour for the instance.

The maximum number of 3 decimal places is supported. The value of the parameter 'SpotStrategy' is 'SpotWithPriceLimit.


attrSpotStrategyRequired

public readonly attrSpotStrategy: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute SpotStrategy: The preemption policy for a pay-as-you-go instance.

This parameter takes effect when the value of the parameter 'InstanceChargeType' is 'PostPaid.


attrSystemDiskRequired

public readonly attrSystemDisk: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute SystemDisk: System disk configuration.


attrTagsRequired

public readonly attrTags: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute Tags: The tags of the launch template.


attrTemplateResourceGroupIdRequired

public readonly attrTemplateResourceGroupId: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute TemplateResourceGroupId: Q.


attrTemplateTagRequired

public readonly attrTemplateTag: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute TemplateTag: The tags of the launch template.


attrUserDataRequired

public readonly attrUserData: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute UserData: The user-defined data of the instance must be encoded in Base64.

The maximum original data is 16KB.


attrVersionDescriptionRequired

public readonly attrVersionDescription: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute VersionDescription: Instance launch template version description.

2 to 256 English or Chinese characters in length and cannot start with' http:// 'or' https.


attrVpcIdRequired

public readonly attrVpcId: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute VpcId: VPC Id.


attrVSwitchIdRequired

public readonly attrVSwitchId: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute VSwitchId: The ID of the vSwitch.


attrZoneIdRequired

public readonly attrZoneId: string | IResolvable;
  • Type: string | @alicloud/ros-cdk-core.IResolvable

Attribute ZoneId: The ID of the zone to which the instance belongs.


propsRequired

public readonly props: LaunchTemplateProps;