forked from aliyun/ros-templates
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathassign-private-ip-addresses.yml
42 lines (42 loc) · 1010 Bytes
/
assign-private-ip-addresses.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
ROSTemplateFormatVersion: '2015-09-01'
Description: ECS AssignPrivateIpAddresses resource example
Parameters:
VSwitchId:
Type: String
Label: VSwitch
Description: VSwitch ID
SecurityGroupId:
Type: String
Label: SecurityGroup
Description: Security Group Id.
SecondaryPrivateIpAddressCount:
Type: Number
Label: SecondaryPrivateIpAddressCount
Default: 1
Resources:
ENI:
Type: ALIYUN::ECS::NetworkInterface
Properties:
VSwitchId:
Ref: VSwitchId
SecurityGroupId:
Ref: SecurityGroupId
AssignPrivateIPAddr:
Type: ALIYUN::ECS::AssignPrivateIpAddresses
Properties:
NetworkInterfaceId:
Ref: ENI
SecondaryPrivateIpAddressCount:
Ref: SecondaryPrivateIpAddressCount
DependsOn: ENI
Outputs:
NetworkInterfaceId:
Value:
Fn::GetAtt:
- AssignPrivateIPAddr
- NetworkInterfaceId
PrivateIpAddresses:
Value:
Fn::GetAtt:
- AssignPrivateIPAddr
- PrivateIpAddresses