forked from aliyun/ros-templates
-
Notifications
You must be signed in to change notification settings - Fork 1
/
ecs-instance-group-clone.yml
107 lines (107 loc) · 3.89 KB
/
ecs-instance-group-clone.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
ROSTemplateFormatVersion: '2015-09-01'
Description:
en: According the existing ECS instance, clone a set of ECS instances with the same
configuration(InstanceType, ImageId, InternetChargeType, InternetMaxBandwidthIn,
InternetMaxBandwidthOut, system disk, data disk configurations, VPC properties).
The user only needs to specify SourceInstanceId.
zh-cn: 根据已有的ECS实例,克隆出一组相同配置(InstanceType、ImageId、InternetChargeType、InternetMaxBandwidthIn、InternetMaxBandwidthOut、系统盘、数据盘配置、VPC属性)的ECS实例。
用户只需指定 SourceInstanceId。
Parameters:
InstanceName:
Type: String
Label:
en: Instance Name
zh-cn: 实例名称
Description:
en: '[2, 128] alphanumeric letters, underline, dot or hyphen'
zh-cn: 实例名称;2~128个字符,可包含英文、中文、数字、下划线(_)、点号(.)和连字符(-)。
ConstraintDescription:
en: '[2, 128] characters, consists of uppercase letter, lowercase letter, number
or special characters.'
zh-cn: '[2, 128] 个字符,由大写字母、小写字母、数字或特殊字符组成。'
Default: ClonedECS
MinLength: 2
MaxLength: 128
SourceInstanceId:
Type: String
Label:
en: Source Instance ID
zh-cn: 源实例 ID
Description:
en: The source ECS instance ID to be cloned
zh-cn: 需要克隆的ECS实例ID
AssociationProperty: ALIYUN::ECS::Instance::InstanceId
MaxAmount:
Type: Number
Label:
en: The Maximum of ECS Instances
zh-cn: 最大个数
Description:
en: The maximum of ECS instances, must be greater than or equal to the minimum.
zh-cn: 一次性创建ECS实例的最大个数,必须大于或等于一次性创建ECS实例的最小个数
ConstraintDescription:
en: An integer within [1, 100]
zh-cn: '[1, 100] 内的整数'
Default: 1
MinValue: 1
MaxValue: 100
Password:
Type: String
Label:
en: ECS Instance Password
zh-cn: ECS实例密码
Description:
en: '[8, 30] characters, consists of uppercase letter, lowercase letter, number
or special characters such as ( ) ` ~ ! @ # $ % ^ & * - + = | { } [ ] : ;
‘ < > , . ? / '
zh-cn: '长度为8~30个字符。必须同时包含三项(大、小写字母,数字和特殊符号),支持以下特殊字符:( ) ` ~ ! @ # $ % ^ & *
- + = | { } [ ] : ; ‘ < > , . ? /。'
ConstraintDescription:
en: 'Length 8-30, must contain upper case letters, lower case letters, Numbers,
special symbols three; special characters include: ()`~!@#$%^&*_-+=|{}[]:;''<>,.?/'
zh-cn: 长度8-30,必须包含大写字母、小写字母、数字、特殊符号三种;特殊字符包括:()`~!@#$%^&*_-+=|{}[]:;' <>,.?/
AllowedPattern: '[a-zA-Z0-9-\(\)\`\~\!@\#\$%\^&\*-+=\|\{\}\[\]\:\;\‘\,\.\?\/]*'
MinLength: 8
MaxLength: 30
NoEcho: true
Resources:
ECSInstanceGroup:
Type: ALIYUN::ECS::InstanceGroupClone
Properties:
MaxAmount:
Ref: MaxAmount
Password:
Ref: Password
SourceInstanceId:
Ref: SourceInstanceId
Outputs:
InstanceIds:
Description: The instance ID list of created ecs instance
Value:
Fn::GetAtt:
- ECSInstanceGroup
- InstanceIds
PublicIps:
Description: Public IP address list of created ecs instance.
Value:
Fn::GetAtt:
- ECSInstanceGroup
- PublicIps
ZoneIds:
Description: Zone ID of created instance.
Value:
Fn::GetAtt:
- ECSInstanceGroup
- ZoneIds
Metadata:
ALIYUN::ROS::Interface:
ParameterGroups:
- Parameters:
- InstanceName
- SourceInstanceId
- MaxAmount
- Password
Label:
default: ECS
TemplateTags:
- acs:example:弹性计算:指定SourceInstanceId克隆出相同配置的一组ECS实例