Zack Williams | 2c01053 | 2018-01-18 10:22:57 -0700 | [diff] [blame] | 1 | --- |
Andy Bavier | e6478b2 | 2017-12-21 13:17:56 -0700 | [diff] [blame] | 2 | {# |
| 3 | Copyright 2017-present Open Networking Foundation |
| 4 | |
| 5 | Licensed under the Apache License, Version 2.0 (the "License"); |
| 6 | you may not use this file except in compliance with the License. |
| 7 | You may obtain a copy of the License at |
| 8 | |
| 9 | http://www.apache.org/licenses/LICENSE-2.0 |
| 10 | |
| 11 | Unless required by applicable law or agreed to in writing, software |
| 12 | distributed under the License is distributed on an "AS IS" BASIS, |
| 13 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 14 | See the License for the specific language governing permissions and |
| 15 | limitations under the License. |
| 16 | #} |
| 17 | |
Andy Bavier | e6478b2 | 2017-12-21 13:17:56 -0700 | [diff] [blame] | 18 | tosca_definitions_version: tosca_simple_yaml_1_0 |
| 19 | |
Zack Williams | 2c01053 | 2018-01-18 10:22:57 -0700 | [diff] [blame] | 20 | description: created by mcord profile, need to add M-CORD services later |
Andy Bavier | e6478b2 | 2017-12-21 13:17:56 -0700 | [diff] [blame] | 21 | |
| 22 | imports: |
Andy Bavier | e6478b2 | 2017-12-21 13:17:56 -0700 | [diff] [blame] | 23 | - custom_types/slice.yaml |
| 24 | - custom_types/site.yaml |
| 25 | - custom_types/image.yaml |
| 26 | - custom_types/flavor.yaml |
| 27 | - custom_types/network.yaml |
Andy Bavier | 0d1131e | 2018-01-02 11:27:43 -0700 | [diff] [blame] | 28 | - custom_types/networktemplate.yaml |
Andy Bavier | e6478b2 | 2017-12-21 13:17:56 -0700 | [diff] [blame] | 29 | - custom_types/onosservice.yaml |
| 30 | - custom_types/networkslice.yaml |
| 31 | - custom_types/venbservice.yaml |
| 32 | - custom_types/vspgwcservice.yaml |
| 33 | - custom_types/vspgwcvendor.yaml |
| 34 | - custom_types/vspgwuservice.yaml |
| 35 | - custom_types/vspgwuvendor.yaml |
| 36 | - custom_types/vepcservice.yaml |
| 37 | - custom_types/servicedependency.yaml |
| 38 | - custom_types/mcordsubscriberservice.yaml |
| 39 | |
| 40 | topology_template: |
| 41 | node_templates: |
| 42 | |
| 43 | # site, image, fully created in deployment.yaml |
| 44 | {{ site_name }}: |
| 45 | type: tosca.nodes.Site |
| 46 | properties: |
| 47 | must-exist: true |
| 48 | name: {{ site_name }} |
| 49 | |
Andy Bavier | 0d1131e | 2018-01-02 11:27:43 -0700 | [diff] [blame] | 50 | # flavors |
| 51 | |
Andy Bavier | e6478b2 | 2017-12-21 13:17:56 -0700 | [diff] [blame] | 52 | m1.small: |
| 53 | type: tosca.nodes.Flavor |
| 54 | properties: |
| 55 | name: m1.small |
| 56 | must-exist: true |
| 57 | m1.large: |
| 58 | type: tosca.nodes.Flavor |
| 59 | properties: |
| 60 | name: m1.large |
| 61 | must-exist: true |
| 62 | m1.medium: |
| 63 | type: tosca.nodes.Flavor |
| 64 | properties: |
| 65 | name: m1.medium |
| 66 | must-exist: true |
| 67 | m1.xlarge: |
| 68 | type: tosca.nodes.Flavor |
| 69 | properties: |
| 70 | name: m1.xlarge |
| 71 | must-exist: true |
| 72 | |
Andy Bavier | 0d1131e | 2018-01-02 11:27:43 -0700 | [diff] [blame] | 73 | # images |
Andy Bavier | e6478b2 | 2017-12-21 13:17:56 -0700 | [diff] [blame] | 74 | image-venb: |
| 75 | type: tosca.nodes.Image |
| 76 | properties: |
| 77 | name: image-venb |
| 78 | |
| 79 | image-spgwc: |
| 80 | type: tosca.nodes.Image |
| 81 | properties: |
| 82 | name: image-spgwc |
| 83 | |
| 84 | image-spgwu: |
| 85 | type: tosca.nodes.Image |
| 86 | properties: |
| 87 | name: image-spgwu |
| 88 | |
Andy Bavier | 0d1131e | 2018-01-02 11:27:43 -0700 | [diff] [blame] | 89 | # network templates |
| 90 | private_template: |
| 91 | type: tosca.nodes.NetworkTemplate |
| 92 | properties: |
| 93 | name: private_template |
| 94 | visibility: private |
| 95 | translation: none |
| 96 | vtn_kind: PRIVATE |
| 97 | |
| 98 | flat_template: |
| 99 | type: tosca.nodes.NetworkTemplate |
| 100 | properties: |
| 101 | name: flat_template |
| 102 | visibility: private |
| 103 | translation: none |
| 104 | vtn_kind: FLAT |
| 105 | |
Andy Bavier | e6478b2 | 2017-12-21 13:17:56 -0700 | [diff] [blame] | 106 | # management networks, fully created in management-net.yaml |
| 107 | management: |
| 108 | type: tosca.nodes.Network |
| 109 | properties: |
| 110 | must-exist: true |
| 111 | name: management |
| 112 | |
Zack Williams | 2c01053 | 2018-01-18 10:22:57 -0700 | [diff] [blame] | 113 | {% if use_vtn_net_management_host %} |
| 114 | management_host: |
Andy Bavier | e6478b2 | 2017-12-21 13:17:56 -0700 | [diff] [blame] | 115 | type: tosca.nodes.Network |
| 116 | properties: |
Zack Williams | 2c01053 | 2018-01-18 10:22:57 -0700 | [diff] [blame] | 117 | name: management_host |
Andy Bavier | e6478b2 | 2017-12-21 13:17:56 -0700 | [diff] [blame] | 118 | must-exist: true |
Andy Bavier | e6478b2 | 2017-12-21 13:17:56 -0700 | [diff] [blame] | 119 | {% endif %} |
| 120 | |
Andy Bavier | e6478b2 | 2017-12-21 13:17:56 -0700 | [diff] [blame] | 121 | # ONOS_CORD, fully created in vtn.yaml |
| 122 | service#ONOS_CORD: |
| 123 | type: tosca.nodes.ONOSService |
| 124 | properties: |
| 125 | must-exist: true |
| 126 | name: ONOS_CORD |
| 127 | |
| 128 | # ONOS_Fabric, fully created in fabric.yaml |
| 129 | service#ONOS_Fabric: |
| 130 | type: tosca.nodes.ONOSService |
| 131 | properties: |
| 132 | must-exist: true |
| 133 | name: ONOS_Fabric |
| 134 | |
| 135 | # vENB Service |
| 136 | service#venb: |
| 137 | type: tosca.nodes.VENBService |
| 138 | properties: |
| 139 | name: venb |
| 140 | public_key: {{ lookup('file', config_cord_profile_dir + '/key_import/mcord_rsa.pub') }} |
| 141 | private_key_fn: /opt/xos/services/venb/keys/mcord_rsa |
| 142 | artifacts: |
| 143 | pubkey: /opt/cord_profile/key_import/mcord_rsa.pub |
| 144 | |
| 145 | {{ site_name }}_venb: |
| 146 | description: vENB Service Slice |
| 147 | type: tosca.nodes.Slice |
| 148 | properties: |
| 149 | name: {{ site_name }}_venb |
| 150 | default_isolation: vm |
| 151 | network: noauto |
| 152 | requirements: |
| 153 | - site: |
| 154 | node: mysite |
| 155 | relationship: tosca.relationships.BelongsToOne |
| 156 | - service: |
| 157 | node: service#venb |
| 158 | relationship: tosca.relationships.BelongsToOne |
| 159 | - default_image: |
| 160 | node: image-venb |
| 161 | relationship: tosca.relationships.BelongsToOne |
| 162 | - default_flavor: |
| 163 | node: m1.medium |
| 164 | relationship: tosca.relationships.BelongsToOne |
| 165 | |
| 166 | |
| 167 | #vSPGWC Service |
| 168 | service#vspgwc: |
| 169 | type: tosca.nodes.VSPGWCService |
| 170 | properties: |
| 171 | name: vspgwc |
| 172 | public_key: {{ lookup('file', config_cord_profile_dir + '/key_import/mcord_rsa.pub') }} |
| 173 | private_key_fn: /opt/xos/services/vspgwc/keys/mcord_rsa |
| 174 | artifacts: |
| 175 | pubkey: /opt/cord_profile/key_import/mcord_rsa.pub |
| 176 | |
| 177 | {{ site_name }}_vspgwc: |
| 178 | description: SDN controller slice |
| 179 | type: tosca.nodes.Slice |
| 180 | properties: |
| 181 | name: {{ site_name }}_vspgwc |
| 182 | default_isolation: vm |
| 183 | network: noauto |
| 184 | requirements: |
| 185 | - site: |
| 186 | node: mysite |
| 187 | relationship: tosca.relationships.BelongsToOne |
| 188 | - service: |
| 189 | node: service#vspgwc |
| 190 | relationship: tosca.relationships.BelongsToOne |
| 191 | - default_image: |
| 192 | node: image-spgwc |
| 193 | relationship: tosca.relationships.BelongsToOne |
| 194 | - default_flavor: |
| 195 | node: m1.large |
| 196 | relationship: tosca.relationships.BelongsToOne |
| 197 | |
| 198 | intel_vspgwc: |
| 199 | type: tosca.nodes.VSPGWCVendor |
| 200 | properties: |
| 201 | name: intel_vspgwc |
| 202 | requirements: |
| 203 | - image: |
| 204 | node: image-spgwc |
| 205 | relationship: tosca.relationships.BelongsToOne |
| 206 | - flavor: |
| 207 | node: m1.large |
| 208 | relationship: tosca.relationships.BelongsToOne |
| 209 | |
| 210 | |
| 211 | #vSPGWU Service |
| 212 | service#vspgwu: |
| 213 | type: tosca.nodes.VSPGWUService |
| 214 | properties: |
| 215 | name: vspgwu |
| 216 | public_key: {{ lookup('file', config_cord_profile_dir + '/key_import/mcord_rsa.pub') }} |
| 217 | private_key_fn: /opt/xos/services/vspgwu/keys/mcord_rsa |
| 218 | artifacts: |
| 219 | pubkey: /opt/cord_profile/key_import/mcord_rsa.pub |
| 220 | |
| 221 | {{ site_name }}_vspgwu: |
| 222 | description: SDN controller slice |
| 223 | type: tosca.nodes.Slice |
| 224 | properties: |
| 225 | name: {{ site_name }}_vspgwu |
| 226 | default_isolation: vm |
| 227 | network: noauto |
| 228 | requirements: |
| 229 | - site: |
| 230 | node: mysite |
| 231 | relationship: tosca.relationships.BelongsToOne |
| 232 | - service: |
| 233 | node: service#vspgwu |
| 234 | relationship: tosca.relationships.BelongsToOne |
| 235 | - default_image: |
| 236 | node: image-spgwu |
| 237 | relationship: tosca.relationships.BelongsToOne |
| 238 | - default_flavor: |
| 239 | node: m1.xlarge |
| 240 | relationship: tosca.relationships.BelongsToOne |
| 241 | |
| 242 | intel_vspgwu: |
| 243 | type: tosca.nodes.VSPGWUVendor |
| 244 | properties: |
| 245 | name: intel_vspgwu |
| 246 | requirements: |
| 247 | - image: |
| 248 | node: image-spgwu |
| 249 | relationship: tosca.relationships.BelongsToOne |
| 250 | - flavor: |
| 251 | node: m1.xlarge |
| 252 | relationship: tosca.relationships.BelongsToOne |
| 253 | |
| 254 | # vEPC Service |
| 255 | service#vepc: |
| 256 | type: tosca.nodes.VEPCService |
| 257 | properties: |
| 258 | name: vepc |
| 259 | public_key: {{ lookup('file', config_cord_profile_dir + '/key_import/mcord_rsa.pub') }} |
| 260 | private_key_fn: /opt/xos/services/venb/keys/mcord_rsa |
| 261 | artifacts: |
| 262 | pubkey: /opt/cord_profile/key_import/mcord_rsa.pub |
| 263 | |
| 264 | |
| 265 | # ServiceDependencies |
| 266 | venb_vspgwc: |
| 267 | type: tosca.nodes.ServiceDependency |
| 268 | properties: |
| 269 | connect_method: None |
| 270 | requirements: |
| 271 | - subscriber_service: |
| 272 | node: service#venb |
| 273 | relationship: tosca.relationships.BelongsToOne |
| 274 | - provider_service: |
| 275 | node: service#vspgwc |
| 276 | relationship: tosca.relationships.BelongsToOne |
| 277 | |
| 278 | venb_vspgwu: |
| 279 | type: tosca.nodes.ServiceDependency |
| 280 | properties: |
| 281 | connect_method: None |
| 282 | requirements: |
| 283 | - subscriber_service: |
| 284 | node: service#venb |
| 285 | relationship: tosca.relationships.BelongsToOne |
| 286 | - provider_service: |
| 287 | node: service#vspgwu |
| 288 | relationship: tosca.relationships.BelongsToOne |
| 289 | |
| 290 | vspgwc_vspgwu: |
| 291 | type: tosca.nodes.ServiceDependency |
| 292 | properties: |
| 293 | connect_method: None |
| 294 | requirements: |
| 295 | - subscriber_service: |
| 296 | node: service#vspgwc |
| 297 | relationship: tosca.relationships.BelongsToOne |
| 298 | - provider_service: |
| 299 | node: service#vspgwu |
| 300 | relationship: tosca.relationships.BelongsToOne |
| 301 | |
| 302 | # M-CORD Subscriber |
| 303 | service#mcord: |
| 304 | type: tosca.nodes.MCordSubscriberService |
| 305 | properties: |
| 306 | name: mcord |
| 307 | |
| 308 | # ServiceDependency M-CORD to vENB |
| 309 | mcord_venb: |
| 310 | type: tosca.nodes.ServiceDependency |
| 311 | properties: |
| 312 | connect_method: None |
| 313 | requirements: |
| 314 | - subscriber_service: |
| 315 | node: service#venb |
| 316 | relationship: tosca.relationships.BelongsToOne |
| 317 | - provider_service: |
| 318 | node: service#mcord |
| 319 | relationship: tosca.relationships.BelongsToOne |
Andy Bavier | 9670128 | 2018-01-22 20:41:25 -0800 | [diff] [blame] | 320 | |
| 321 | # EPC networks |
| 322 | |
| 323 | {% for network in mcord_networks %} |
| 324 | {{ network['name'] }}: |
| 325 | type: tosca.nodes.Network |
| 326 | properties: |
| 327 | name: {{ network['name'] }} |
| 328 | subnet: {{ network['subnet'] }} |
| 329 | permit_all_slices: {{ network['permit_all_slices'] }} |
| 330 | requirements: |
| 331 | - template: |
| 332 | node: {{ network['template'] }} |
| 333 | relationship: tosca.relationships.BelongsToOne |
| 334 | - owner: |
| 335 | node: {{ site_name }}_{{ network['owner'] }} |
| 336 | relationship: tosca.relationships.BelongsToOne |
| 337 | |
Zack Williams | 2c01053 | 2018-01-18 10:22:57 -0700 | [diff] [blame] | 338 | {% endfor %} |