forked from aliyun/ros-templates
-
Notifications
You must be signed in to change notification settings - Fork 1
/
router-interface-update.yml
83 lines (83 loc) · 2.02 KB
/
router-interface-update.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
ROSTemplateFormatVersion: '2015-09-01'
Description: Vpc RouterInterface resource example
Parameters:
VpcName:
Type: String
Default: mytest
OppositeInterfaceId:
Type: String
Resources:
Vpc:
Type: ALIYUN::ECS::VPC
Properties:
VpcName:
Ref: VpcName
CidrBlock: 192.168.0.0/16
Count: 2
RouterInterfaceAccept:
Type: ALIYUN::VPC::RouterInterface
Properties:
OppositeInterfaceId:
Ref: OppositeInterfaceId
Description: Accepting Side
RouterType: VRouter
RouterId:
Fn::Select:
- 1
- Fn::GetAtt:
- Vpc
- VRouterId
Role: AcceptingSide
OppositeRouterType: VRouter
InstanceChargeType: PostPaid
RouterInterfaceInit:
Type: ALIYUN::VPC::RouterInterface
Properties:
OppositeInterfaceId:
Ref: RouterInterfaceAccept
OppositeRouterId:
Fn::Select:
- 1
- Fn::GetAtt:
- Vpc
- VRouterId
OppositeInterfaceOwnerId:
Ref: ALIYUN::TenantId
OppositeRouterType: VRouter
Description: Initiating Side
RouterType: VRouter
RouterId:
Fn::Select:
- 0
- Fn::GetAtt:
- Vpc
- VRouterId
Role: InitiatingSide
Spec: Mini.2
InstanceChargeType: PostPaid
DependsOn: RouterInterfaceAccept
PeeringRouterInterfaceBinding:
Type: ALIYUN::VPC::PeeringRouterInterfaceBinding
Properties:
OppositeInterfaceId:
Ref: RouterInterfaceInit
RouterInterfaceId:
Ref: RouterInterfaceAccept
PeeringRouterInterfaceConnection:
Type: ALIYUN::VPC::PeeringRouterInterfaceConnection
Properties:
OppositeInterfaceId:
Ref: RouterInterfaceAccept
RouterInterfaceId:
Ref: RouterInterfaceInit
Outputs:
OppositeInterfaceId:
Value:
Fn::GetAtt:
- PeeringRouterInterfaceConnection
- OppositeInterfaceId
RouterInterfaceId:
Value:
Fn::GetAtt:
- PeeringRouterInterfaceConnection
- RouterInterfaceId