blob: f6fc2eaa6129753e7306a54835956a47a3f1d159 [file] [log] [blame]
Wei-Yu Chen4336af32017-10-21 13:45:57 +08001{#
2Copyright 2017-present Open Networking Foundation
3
4Licensed under the Apache License, Version 2.0 (the "License");
5you may not use this file except in compliance with the License.
6You may obtain a copy of the License at
7
8http://www.apache.org/licenses/LICENSE-2.0
9
10Unless required by applicable law or agreed to in writing, software
11distributed under the License is distributed on an "AS IS" BASIS,
12WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13See the License for the specific language governing permissions and
14limitations under the License.
15#}
16
17
18tosca_definitions_version: tosca_simple_yaml_1_0
19
20description: created by platform-install, need to add M-CORD services later
21
22imports:
23 - custom_types/xos.yaml
24 - custom_types/slice.yaml
25 - custom_types/site.yaml
26 - custom_types/image.yaml
27 - custom_types/flavor.yaml
28 - custom_types/network.yaml
29 - custom_types/networkslice.yaml
30 - custom_types/vspgwuservice.yaml
31 - custom_types/vspgwuvendor.yaml
32 - custom_types/vspgwutenant.yaml
33
34topology_template:
35 node_templates:
36
37# site, image, fully created in deployment.yaml
38 {{ site_name }}:
39 type: tosca.nodes.Site
40 properties:
41 must-exist: true
42 name: {{ site_name }}
43
44 m1.small:
45 type: tosca.nodes.Flavor
46 properties:
47 name: m1.small
48 must-exist: true
49
50 trusty-server-multi-nic:
51 type: tosca.nodes.Image
52 properties:
53 name: trusty-server-multi-nic
54 must-exist: true
55
56# management networks, fully created in management-net.yaml
57 management:
58 type: tosca.nodes.Network
59 properties:
60 must-exist: true
61 name: management
62
63{% if use_management_hosts %}
64 management_hosts:
65 type: tosca.nodes.Network
66 properties:
67 must-exist: true
68 name: management_hosts
69{% endif %}
70
71# sgi_network is for connectivity between VMs, fully created in sgi-net.yaml
72 sgi_network:
73 type: tosca.nodes.Network
74 properties:
75 must-exist: true
76 name: sgi_network
77
78# sbi_network is for connectivity between VMs, fully created in sbi-net.yaml
79 sbi_network:
80 type: tosca.nodes.Network
81 properties:
82 must-exist: true
83 name: sbi_network
84
85# s1u_network is for connectivity between VMs, fully created in s1u-net.yaml
86 s1u_network:
87 type: tosca.nodes.Network
88 properties:
89 must-exist: true
90 name: s1u_network
91
92# CORD Services
93 service#vspgwu:
94 type: tosca.nodes.VSPGWUService
95 properties:
96 name: vspgwu
97 public_key: {{ lookup('file', config_cord_profile_dir + '/key_import/mcord_rsa.pub') }}
98 private_key_fn: /opt/xos/services/vspgwu/keys/mcord_rsa
99 artifacts:
100 pubkey: /opt/cord_profile/key_import/mcord_rsa.pub
101
102# CORD Slices
103 {{ site_name }}_vspgwu:
104 description: SDN controller slice
105 type: tosca.nodes.Slice
106 properties:
107 name: {{ site_name }}_vspgwu
108 default_isolation: vm
109 network: noauto
110 requirements:
111 - site:
112 node: mysite
113 relationship: tosca.relationships.BelongsToOne
114 - service:
115 node: service#vspgwu
116 relationship: tosca.relationships.BelongsToOne
117 - default_image:
118 node: trusty-server-multi-nic
119 relationship: tosca.relationships.BelongsToOne
120 - default_flavor:
121 node: m1.small
122 relationship: tosca.relationships.BelongsToOne
123
124# CORD Service Instances
125
126 intel_vspgwu:
127 type: tosca.nodes.VSPGWUVendor
128 properties:
129 name: intel_vspgwu
130 requirements:
131 - image:
132 node: trusty-server-multi-nic
133 relationship: tosca.relationships.BelongsToOne
134 - flavor:
135 node: m1.small
136 relationship: tosca.relationships.BelongsToOne
137
138 serviceinstance#vspgwu_instance:
139 type: tosca.nodes.VSPGWUTenant
140 properties:
141 name: vspgwu_instance1
142 requirements:
143 - vspgwu_vendor:
144 node: intel_vspgwu
145 relationship: tosca.relationships.BelongsToOne
146 - owner:
147 node: service#vspgwu
148 relationship: tosca.relationships.BelongsToOne
149
150# CORD NetworkSlices
151 vspgwu_slice_management_network:
152 type: tosca.nodes.NetworkSlice
153 requirements:
154 - network:
155 node: management
156 relationship: tosca.relationships.BelongsToOne
157 - slice:
158 node: {{ site_name }}_vspgwu
159 relationship: tosca.relationships.BelongsToOne
160
161 vspgwu_slice_sgi_network:
162 type: tosca.nodes.NetworkSlice
163 requirements:
164 - network:
165 node: sgi_network
166 relationship: tosca.relationships.BelongsToOne
167 - slice:
168 node: {{ site_name }}_vspgwu
169 relationship: tosca.relationships.BelongsToOne
170
171 vspgwu_slice_sbi_network:
172 type: tosca.nodes.NetworkSlice
173 requirements:
174 - network:
175 node: sbi_network
176 relationship: tosca.relationships.BelongsToOne
177 - slice:
178 node: {{ site_name }}_vspgwu
179 relationship: tosca.relationships.BelongsToOne
180
181 vspgwu_slice_s1u_network:
182 type: tosca.nodes.NetworkSlice
183 requirements:
184 - network:
185 node: s1u_network
186 relationship: tosca.relationships.BelongsToOne
187 - slice:
188 node: {{ site_name }}_vspgwu
189 relationship: tosca.relationships.BelongsToOne